News:

Download Pelles C here: http://www.smorgasbordet.com/pellesc/

Main Menu

From 32 bit to 64bit

Started by bitcoin, June 22, 2020, 10:56:44 PM

Previous topic - Next topic

bitcoin

Hello
i try to re-write my program to work in native 64bit.

Many errors with memory access, because many code such as functionAddres = (DWORD)GetProcAddress(curDllModule, pFunction);
In 64bit address may be greater then DWORD value.. Can I change all pointers to DWORD_PTR ? Or I must use ULONG?

Pelle

DWORD_PTR should work fine. Also works with ULONG_PTR. ULONG is same as DWORD, so not much help there...
/Pelle

bitcoin

Thank you Pelle.

DWORD64 is equ DWORD_PTR in 64bit? Or this is different data types?

Pelle

#3
Quote from: bitcoin on June 23, 2020, 03:52:03 PM
DWORD64 is equ DWORD_PTR in 64bit? Or this is different data types?
It's effectively the same thing. Using DWORD_PTR for an address type is *maybe* more informative, but who knows...?

EDIT: see https://docs.microsoft.com/en-us/windows/win32/winprog/windows-data-types
/Pelle