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 — src: add missing 'inline' keywords by bnoordhuis · Pull Request #6056 · nodejs/node

Conversation

@bnoordhuis

@bnoordhuis bnoordhuis commented Apr 5, 2016

Copy link
Copy Markdown
Member

Pull Request check-list

  • Does make -j8 test (UNIX) or vcbuild test nosign (Windows) pass with
    this change (including linting)?
  • Is the commit message formatted according to [CONTRIBUTING.md][0]?
  • If this change fixes a bug (or a performance problem), is a regression
    test (or a benchmark) included?
  • Is a documentation update included (if this change modifies
    existing APIs, or introduces new ones)?

Affected core subsystem(s)

build, src

Description of change

  • src: add missing 'inline' keywords
  • build: turn on --gc-sections on linux and freebsd

CI: https://ci.nodejs.org/job/node-test-pull-request/2160/

Sorry, something went wrong.

Uh oh!

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

All reactions
@bnoordhuis bnoordhuis added the build Issues and PRs related to Node.js builds or CI infrastructure. label Apr 5, 2016
@bnoordhuis

bnoordhuis commented Apr 5, 2016

Copy link
Copy Markdown
Member Author

Apropos --gc-sections, the alternative is to drop the -fdata-sections and -ffunction-sections flags. I'm on a laptop and I didn't feel like recompiling and benchmarking everything to see if it makes a difference. :-)

All reactions

Sorry, something went wrong.

Uh oh!

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

@bnoordhuis
bnoordhuis force-pushed the gc-sections branch from 29cfaa8 to 2177241 Compare April 5, 2016 15:41
@bnoordhuis

bnoordhuis commented Apr 5, 2016

Copy link
Copy Markdown
Member Author

Okay, --gc-sections clearly doesn't work reliably on FreeBSD and pLinux. I've dropped that commit and I'll file a new PR that removes -fdata-sections and -ffunction-sections. CI: https://ci.nodejs.org/job/node-test-pull-request/2164/

All reactions

Sorry, something went wrong.

Uh oh!

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

@cjihrig

cjihrig commented Apr 5, 2016

Copy link
Copy Markdown
Contributor

LGTM

All reactions

Sorry, something went wrong.

Uh oh!

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

@bnoordhuis
src: add missing 'inline' keywords
0d41463
The BaseObject constructor and destructor should not have external
linkage because BaseObject is a header-only construct.  Add the
necessary 'inline' keywords.

PR-URL: nodejs#6056
Reviewed-By: Colin Ihrig <[email protected]>
@bnoordhuis
bnoordhuis force-pushed the gc-sections branch from 2177241 to 0d41463 Compare April 5, 2016 18:01
@bnoordhuis bnoordhuis closed this Apr 5, 2016
@bnoordhuis
bnoordhuis deleted the gc-sections branch April 5, 2016 18:01
@bnoordhuis
bnoordhuis merged commit 0d41463 into nodejs:master Apr 5, 2016
@bnoordhuis bnoordhuis mentioned this pull request Apr 6, 2016
deps: upgrade to V8 4.9.385.35 #6077
Merged
@ofrobots ofrobots changed the title build: turn on --gc-sections on linux and freebsd src: add missing 'inline' keywords Apr 6, 2016
bnoordhuis added a commit to bnoordhuis/io.js that referenced this pull request Apr 7, 2016
@bnoordhuis
build: remove -f{data,function}-sections flags
71544c5
We don't link with `--gc-sections` because it's unreliable with some
toolchains, so all these flags do is make the compiler generate slightly
worse code.  Drop them.

Refs: nodejs#6056
PR-URL: nodejs#6077
Reviewed-By: Trevor Norris <[email protected]>
@jasnell

jasnell commented Apr 7, 2016

Copy link
Copy Markdown
Member

@bnoordhuis ... does this need to happen in v4 also?

All reactions

Sorry, something went wrong.

Uh oh!

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

@bnoordhuis

bnoordhuis commented Apr 7, 2016

Copy link
Copy Markdown
Member Author

It's not critical but yes.

All reactions

Sorry, something went wrong.

Uh oh!

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

@jasnell jasnell added the lts-watch-v4.x label Apr 7, 2016
@mscdex

mscdex commented Apr 8, 2016

Copy link
Copy Markdown
Contributor

A bit late to the party here but what about the possibility of enabling the flags on known working platforms?

All reactions

Sorry, something went wrong.

Uh oh!

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

@bnoordhuis

bnoordhuis commented Apr 8, 2016

Copy link
Copy Markdown
Member Author

I didn't run extensive tests but I don't think it's really worth the trouble. It trims about 16K from the 20 MB binary (16 MB stripped) and it seems to negatively impact gcc's ability to do intra-procedural optimizations (maybe not when LTO is enabled but we don't do that, and we wouldn't need the flags in that case anyway.)

All reactions

Sorry, something went wrong.

Uh oh!

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

MylesBorins pushed a commit that referenced this pull request Apr 19, 2016
@bnoordhuis Myles Borins
src: add missing 'inline' keywords
188ecef
The BaseObject constructor and destructor should not have external
linkage because BaseObject is a header-only construct.  Add the
necessary 'inline' keywords.

PR-URL: #6056
Reviewed-By: Colin Ihrig <[email protected]>
MylesBorins pushed a commit that referenced this pull request Apr 19, 2016
@bnoordhuis Myles Borins
build: remove -f{data,function}-sections flags
b8649e3
We don't link with `--gc-sections` because it's unreliable with some
toolchains, so all these flags do is make the compiler generate slightly
worse code.  Drop them.

Refs: #6056
PR-URL: #6077
Reviewed-By: Trevor Norris <[email protected]>
MylesBorins pushed a commit that referenced this pull request Apr 20, 2016
@bnoordhuis Myles Borins
src: add missing 'inline' keywords
f6d16c1
The BaseObject constructor and destructor should not have external
linkage because BaseObject is a header-only construct.  Add the
necessary 'inline' keywords.

PR-URL: #6056
Reviewed-By: Colin Ihrig <[email protected]>
MylesBorins pushed a commit that referenced this pull request Apr 20, 2016
@bnoordhuis Myles Borins
build: remove -f{data,function}-sections flags
8952330
We don't link with `--gc-sections` because it's unreliable with some
toolchains, so all these flags do is make the compiler generate slightly
worse code.  Drop them.

Refs: #6056
PR-URL: #6077
Reviewed-By: Trevor Norris <[email protected]>
@MylesBorins MylesBorins mentioned this pull request Apr 20, 2016
V5.10.2 proposal #6311
Closed
MylesBorins pushed a commit that referenced this pull request Apr 20, 2016
@bnoordhuis Myles Borins
src: add missing 'inline' keywords
fbc99ba
The BaseObject constructor and destructor should not have external
linkage because BaseObject is a header-only construct.  Add the
necessary 'inline' keywords.

PR-URL: #6056
Reviewed-By: Colin Ihrig <[email protected]>
MylesBorins pushed a commit that referenced this pull request Apr 20, 2016
@bnoordhuis Myles Borins
build: remove -f{data,function}-sections flags
a5f8d0c
We don't link with `--gc-sections` because it's unreliable with some
toolchains, so all these flags do is make the compiler generate slightly
worse code.  Drop them.

Refs: #6056
PR-URL: #6077
Reviewed-By: Trevor Norris <[email protected]>
This was referenced Apr 21, 2016
V5.11.0 proposal #6321
Closed
V5.11.0 proposal #6322
Closed
MylesBorins pushed a commit that referenced this pull request May 3, 2016
@bnoordhuis Myles Borins
src: add missing 'inline' keywords
786f576
The BaseObject constructor and destructor should not have external
linkage because BaseObject is a header-only construct.  Add the
necessary 'inline' keywords.

PR-URL: #6056
Reviewed-By: Colin Ihrig <[email protected]>
@MylesBorins MylesBorins added land-on-v4.x and removed lts-watch-v4.x labels May 3, 2016
MylesBorins pushed a commit that referenced this pull request May 6, 2016
@bnoordhuis Myles Borins
src: add missing 'inline' keywords
3a1c14b
The BaseObject constructor and destructor should not have external
linkage because BaseObject is a header-only construct.  Add the
necessary 'inline' keywords.

PR-URL: #6056
Reviewed-By: Colin Ihrig <[email protected]>
MylesBorins pushed a commit that referenced this pull request May 18, 2016
@bnoordhuis Myles Borins
src: add missing 'inline' keywords
2942cff
The BaseObject constructor and destructor should not have external
linkage because BaseObject is a header-only construct.  Add the
necessary 'inline' keywords.

PR-URL: #6056
Reviewed-By: Colin Ihrig <[email protected]>
@MylesBorins MylesBorins mentioned this pull request May 18, 2016
v4.4.5 proposal #6824
Merged
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.

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.

5 participants

@bnoordhuis @cjihrig @jasnell @mscdex @MylesBorins
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 01402503 — 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.