This evening I got the the following Windows XP error message on starting Firefox immediately after upgrading it from version 3.0 to 3.6.
The procedure entry point IsThreadDesktopComposited could not be located in the dynamic link library USER32.dll
I had just finished upgrading several other software packages (Notepad++ and OpenOffice amongst them) and I assumed that one of these had done something to upset Firefox.
A search on the web revealed several blog posts which suggested that this problem could be fixed by renaming or deleting the file dwmapi.dll from the directory C:\Windows\system32. Dwmapi.dll is only required on Windows Vista (and presumably later), and should not be present on Windows XP.
On looking, I found that there was no dwmapi.dll in the C:\Windows\system32 directory, but there was one in the C:\Windows\system directory so I renamed that to dwmapi.dll.disabled. However, whenever I tried to rename this file through Windows Explorer, it would revert to its original name after a few seconds (presumably Windows trying to prevent malicious or accidental damage to system files?). So I had to go into the command line to rename it permanently: click Start, click Run..., enter cmd, click OK, then enter
rename dwmapi.dll dwmapi.dll.disabled
This fixed the problem and Firefox now starts up correctly.
I have not identified the software package that installed the unnecessary dwmapi.dll.