I think under windows x64, it still uses user32.dll and a bunch of other 32 bit libraries. Why there is no user64.dll?
USER32. DLL implements the Windows USER component that creates and manipulates the standard elements of the Windows user interface, such as the desktop, windows, and menus. It thus enables programs to implement a graphical user interface (GUI) that matches the Windows look and feel.
On 64-bit Windows, a 64-bit process cannot load a 32-bit dynamic-link library (DLL). Additionally, a 32-bit process cannot load a 64-bit DLL. However, 64-bit Windows supports remote procedure calls (RPC) between 64-bit and 32-bit processes (both on the same computer and across computers).
If the first DLL in the path is 32 bit and your app is 32 bit, then the DLL load will work. If the app is 64 bit, it will fail to load the DLL and the process will abort. If you want two DLLs to coexist on the system path, you need to give them unique file names.
There is no user64. dll for the exact same reason you just described, . NET program can be agnostic to CPU architecture so the same code needs to work on x86 and x64. If you take your program to x86 platform, it will still run without any modifications.
C:\Windows\System32\user32.dll
is a 64-bit library.
The 32-bit version is in C:\Windows\SysWOW64\user32.dll
.
They can't change any names because that would break all sorts of programs with hard-coded paths.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With