微软资深工程师 Raymond Chen 于 10 月 29 日在其博客《The Old New Thing》中撰文,详细解释了 Windows 系统中长按电源键背后的内部运作逻辑 1。据其介绍,当用户持续按住电源键约 8 秒后,Windows 内核会识别出这一操作意图为强制关机,并尝试在随后的 4 秒内导出内核转储文件 1。如果用户继续按压直至总时长达到约 12 秒,计算机将触发硬件级别的强制关机,此时操作系统不再接收到任何通知 1。
由上述过程产生的转储文件在微软内部被专门归类为“长按电源键故障”(LPBH)1。在这些数据中,系统还会记录屏幕是否完全呈现黑色像素的状态,此类“黑屏 LPBH”案例会被送往专门团队进行分析 1。造成黑屏现象的原因可能包括显卡驱动损坏、桌面合成器输出黑色像素、无进程绘制屏幕或绘图进程卡死等情况 1。
Microsoft senior engineer Raymond Chen updated his blog "The Old New Thing" on October 29, 2024, explaining the internal mechanics of holding down a computer's power button 1. The process involves distinct stages where the operating system attempts to save diagnostic data before hardware forces a complete shutdown 1.
According to Chen’s explanation, if a user holds the power button for approximately eight seconds, the Windows kernel identifies this as a forced shutdown and attempts to export a kernel dump file within the next four seconds 1. These specific dump files are internally categorized by Microsoft as "Long Pressed Power Button Hang" (LPBH) incidents 1. If the user continues to hold the button until roughly twelve seconds have elapsed, a hardware-level shutdown is triggered, causing the computer to lose power without further notification to the operating system 1.
To aid in diagnosis, the system records whether the screen was displaying entirely black pixels at the moment of the forced shutdown 1. Data from these "black screen LPBH" events is forwarded to a dedicated analysis team to investigate potential causes 1. The underlying reasons for a black screen during such incidents may include corrupted graphics drivers, the desktop compositor outputting only black pixels, no active processes rendering the display, or drawing processes becoming unresponsive 1.
评论
还没有评论,欢迎留下第一条。