GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [v24.x backport] build,win: replace LTCG with Thin LTO for releases by StefanStojanovic · Pull Request #66170 · nodejs/node

Conversation

@StefanStojanovic

@StefanStojanovic StefanStojanovic commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

This effectively backports enabling thin LTO for Windows releases on v24. This has been enabled on v26 since version 26.3.0 and has been stable. It includes 2 PRs previously landed on main. The main one, and a follow-up. I have tested this in the release CI in this custom build and it works.

One more thing to add here: PGO changes were already backported to v24 earlier, and with my latest release CI changes, they will be effectively from the next release. It would be good to have both enabled in time for the next release, and merging this backport will do just that.

cc @nodejs/releasers, @nodejs/platform-windows.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@StefanStojanovic
build,win: replace LTCG with Thin LTO for releases
e595379
PR-URL: nodejs#63114
Refs: nodejs#61964
Reviewed-By: Michaël Zasso <[email protected]>
Signed-off-by: StefanStojanovic <[email protected]>
@StefanStojanovic StefanStojanovic added windows Issues and PRs related to the Windows platform. build Issues and PRs related to Node.js builds or CI infrastructure. release Issues and PRs related to Node.js releases. labels Sep 21, 2026
@nodejs-github-bot

nodejs-github-bot commented Sep 21, 2026

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/gyp
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. v24.x Issues that can be reproduced on v24.x or PRs targeting the v24.x-staging branch. labels Sep 21, 2026
@richardlau

richardlau commented Sep 21, 2026

Copy link
Copy Markdown
Member

This effectively backports enabling thin LTO for Windows releases on v24. This has been enabled on v26 since version 26.3.0 and has been stable. It includes 2 PRs previously landed on main. The main one, and a follow-up. I have tested this in the release CI in this custom build and it works.

I'm a little worried about addons and the breakage that occurred with Node.js 26 when LTO was enabled.

  • Windows Node 26 enable_thin_lto=true breaks MSVC native addon builds (lldltojobs / -flto=thin) #64674
  • GitHub Actions are failing on Windows on Node.js v26 node-gyp#3327

While nodejs/node-gyp#3331 has fixed that, it was fixed in node-gyp@13 and AFAIK that is not yet in npm (or at least not in a version of npm that is in Node.js 26/24).

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@StefanStojanovic

StefanStojanovic commented Sep 29, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the feedback @richardlau. I remember the node-gyp issue, but as you said, it is fixed, and there is a workaround: updating node-gyp. Since this wasn't a blocker for v26, I didn't think it would be for v24 either. Although v24 is an LTS, v26 is not there yet, so maybe that makes it harder to backport this?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@richardlau

richardlau commented Sep 29, 2026

Copy link
Copy Markdown
Member

I naturally lean towards not knowingly breaking users on a release line. While the user could manually update node-gyp, it's not exactly trivial to do so.

cc @nodejs/releasers thoughts?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@aduh95
aduh95 marked this pull request as draft October 6, 2026 13:07
@StefanStojanovic

StefanStojanovic commented Oct 26, 2026

Copy link
Copy Markdown
Contributor Author

Hey @richardlau, I forgot to ask you one thing while we were discussing this: as described in nodejs/Release#1161, npm v12 won't land in anything earlier than v27. It's also worth mentioning that npm v12 has node-gyp v13, while npm v11 (which is in Node.js v26 and v24) has node-gyp v12. I do not know how npm minor releases work or whether it is likely that a new version of npm v11 will release with node-gyp v13, but if that doesn't happen, it makes this backport PR impossible to land. Correct?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@richardlau

richardlau commented Oct 26, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Hey @richardlau, I forgot to ask you one thing while we were discussing this: as described in nodejs/Release#1161, npm v12 won't land in anything earlier than v27. It's also worth mentioning that npm v12 has node-gyp v13, while npm v11 (which is in Node.js v26 and v24) has node-gyp v12. I do not know how npm minor releases work or whether it is likely that a new version of npm v11 will release with node-gyp v13, but if that doesn't happen, it makes this backport PR impossible to land. Correct?

I would be uncomfortable landing it in that situation, so yes I think it would make this impossible to land if the bundled node-gyp in npm doesn't work with it.

StefanStojanovic reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@StefanStojanovic StefanStojanovic mentioned this pull request Nov 6, 2026
Backport the Windows addon LTO fix to node-gyp v12.x nodejs/node-gyp#3391
Open
@aduh95
aduh95 force-pushed the v24.x-staging branch from 145c7da to 87dad9f Compare November 11, 2026 16:33
@aduh95
aduh95 force-pushed the v24.x-staging branch from f43022f to c039ef5 Compare November 21, 2026 16:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

build Issues and PRs related to Node.js builds or CI infrastructure. needs-ci PRs that need a full CI run. release Issues and PRs related to Node.js releases. v24.x Issues that can be reproduced on v24.x or PRs targeting the v24.x-staging branch. windows Issues and PRs related to the Windows platform.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@StefanStojanovic @nodejs-github-bot @richardlau
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.