Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump minimal supported Windows version to Windows Vista (0x0600). #499

Open
wants to merge 4 commits into
base: Cog
Choose a base branch
from

Conversation

marceltaeumel
Copy link
Contributor

Also fixes a minor issue in MSVC Makefile for 64x64, which tried 0x0801 for Windows 8 and 0x1001 for Windows 10. The latter would actually be 0x0A00. See https://docs.microsoft.com/de-de/cpp/porting/modifying-winver-and-win32-winnt

Also in the Makefile for 64x64, define both _WIN32 and _WIN64. See https://docs.microsoft.com/en-us/cpp/preprocessor/predefined-macros

Also in the Makefile for 64x64, define both WIN32 and WIN64 because those can be used to identify the Windows platform in application code such as in processors/IA32/bochs. I am not aware of any #ifdef WIN64 at the moment. Most code uses #ifdef _WIN64 to check for that.

Note that, having defined both _WIN32 and _WIN64, code for 32-bit and 64-bit must always begin with #ifdef _WIN64 and only then #elif _WIN32.

I think that the MSVC compiler defines _WIN32 and _WIN64 automatically. Yet, now it is documented in the Makefile.

Also fixes a minor issue in MSVC Makefile for 64x64, which tried 0x0801 for Windows 8 and 0x1001 for Windows 10. The latter would actually be 0x0A00. See https://docs.microsoft.com/de-de/cpp/porting/modifying-winver-and-win32-winnt

Also in the Makefile for 64x64, define both _WIN32 and _WIN64. See https://docs.microsoft.com/en-us/cpp/preprocessor/predefined-macros

Also in the Makefile for 64x64, define both WIN32 and WIN64 because those can be used to identify the Windows platform in application code such as in processors/IA32/bochs. I am not aware of any #ifdef WIN64 at the moment. Most code uses #ifdef _WIN64 to check for that.

Note that, having defined both _WIN32 and _WIN64, code for 32-bit and 64-bit must always begin with #ifdef _WIN64 and only then #ifdef _WIN32.

I think that the MSVC compiler defines _WIN32 and _WIN64 automatically. Yet, now it is documented in the Makefile.
@marceltaeumel
Copy link
Contributor Author

That error on TravisCI is misleading. All builds pass.

# Set minimum version to WindowsXP (see /cygwin/usr/include/w32api/w32api.h)
WINVER:=-D_WIN32_WINNT=0x0501 -DWINVER=0x0501
# Set minimum version to Windows 8 (see /cygwin/usr/include/w32api/w32api.h)
WINVER:=-D_WIN32_WINNT=0x0602 -DWINVER=0x0602
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As suggested on the mailing list, I would just use 0x0600

See also https://docs.microsoft.com/en-us/cpp/porting/modifying-winver-and-win32-winnt?view=vs-2019 for the list of _WIN32_WINNT version.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How would you feel about setting minimum supported version to 8.0? I want to do this because of the GetSystemTimePreciseAsFileTime function, which appears in 8.0 nd neatly solves the time issues in the win32 VM (use of the millisecond clock to derive greater precision than the 15ms tick in GetSystemTimeAsFileTime causes significant direct over the course of several days).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can have 0x6000 (Vista) and use that function. Ping me in a week or so, when I'm back from vacation

if (nameinfo == NULL) {
return -1;
}
nameinfo = alloca(size);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not, alloca is a bit shorter, but the pairs of malloc and free seems correct here...
I'd rather consider this change as un-necessary.

@marceltaeumel marceltaeumel changed the title Bump minimal supported Windows version to Windows 8 (0x0602). Bump minimal supported Windows version to Windows Vista (0x0600). May 14, 2020
@krono
Copy link
Member

krono commented Sep 10, 2020

wanna merge? care to first update build.win64x64/common/Makefile.msvc.tools ?

hogoww referenced this pull request in hogoww/opensmalltalk-vm Dec 23, 2021
…ver with false ] on method [ setIsRememberedOf:to: ]
hogoww referenced this pull request in hogoww/opensmalltalk-vm Dec 23, 2021
…er with false ] on method [ setIsRememberedOf:to: ] KILLED by 12/24 test cases.
hogoww referenced this pull request in hogoww/opensmalltalk-vm Feb 26, 2022
hogoww referenced this pull request in hogoww/opensmalltalk-vm Feb 26, 2022
…tselfClassIndexPun ] 9/9 Test Cases are NOT EQUIVALENT
guillep added a commit to tesonep/opensmalltalk-vm that referenced this pull request May 12, 2023
Become should not forget to remember
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants