Windows 7 had a bug that caused startup to slow down when using a solid color wallpaper


by

Richard Gillin

Windows has included a variety of wallpaper images for the desktop background from the beginning, but it is also possible to set a solid color that displays only the color selected from the color palette instead of a wallpaper image. Raymond Chen, a long-time developer at Microsoft and a knowledgeable about the history of Windows, explains the bug that existed in Windows 7 that caused startup to slow down when a solid color background was set.

Why did Windows 7, for a few months, log on slower if you have a solid color background? - The Old New Thing
https://devblogs.microsoft.com/oldnewthing/20250428-00/?p=111121

Windows 7 users with a solid background color faced delayed login process — it took four months for Microsoft to fix | Tom's Hardware
https://www.tomshardware.com/software/windows/windows-7-users-with-a-solid-background-color-faced-delayed-login-process-it-took-four-months-for-microsoft-to-fix

Chen himself said he had been using a solid blue-green background since Windows 95. But he was surprised when Microsoft published a support article about a problem with Windows 7 and Windows Server 2008 R2 in which a welcome screen would be displayed for 30 seconds during the logon process if the desktop background was set to a solid color.

Cheng attributes the problem to the design of Windows 7's logon system.

After logon authentication, Windows sets up the desktop by creating the taskbar, loading and initializing system service components, creating desktop windows and arranging icons, loading and displaying wallpaper, etc. The logon system continues to display the Welcome screen until all these components report that they are ready or 30 seconds have elapsed.



The problem was that the background readiness reporting was baked into the bitmap wallpaper code, so if you were using a solid color background the wallpaper wouldn't be reported as ready.
InitializeWallpaper()
{
if (wallpaper bitmap defined)
{
LoadWallpaperBitmap();
}
}

LoadWallpaperBitmap()
{
locate the bitmap on disk
load it into memory
Paint it on screen
Report(WallpaperReady);
}[/code]



With this structure, if there is no wallpaper, the readiness will never be reported and the logon system will wait forever for the report and eventually switch over with a 30 second timeout.

A similar problem occurred when the 'Hide desktop icons' group policy was enabled. This was because the group policy was added later, so a conditional branch 'if the policy allows' was added to the original code, and the range of that condition included the reporting of readiness.


By Petar Spaseski

This issue was fixed in November 2009, about four months after Windows 7 was released.

Cheng added that the reason he prefers solid color backgrounds is because using 0.75MB of wallpaper was inefficient when there were only 4MB or 8MB of memory, and because using the default settings makes it easier to report bugs. Mark Tyson, editor of Tom's Hardware, also said, 'I also used solid color backgrounds to reduce RAM usage and reduce the strain on the hard disk.'

in Software, Posted by log1i_yk