-
Notifications
You must be signed in to change notification settings - Fork 7.3k
Reoncile v0.12 with new CI #25541
Reoncile v0.12 with new CI #25541
Changes from all commits
2086810
67ebb68
0a65e72
7c8db14
77dbf07
f6cf940
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -127,6 +127,9 @@ test-all-http1: test-build | |
test-all-valgrind: test-build | ||
$(PYTHON) tools/test.py --mode=debug,release --valgrind | ||
|
||
test-ci: | ||
$(PYTHON) tools/test.py -ptap --logfile test.tap --mode=release --arch=$(DESTCPU) simple message internet | ||
|
||
test-release: test-build | ||
$(PYTHON) tools/test.py --mode=release | ||
|
||
|
@@ -306,11 +309,11 @@ $(PKG): release-only | |
rm -rf $(PKGDIR) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. do we know if snapshots are "fixed" in this version of v8? my recollection is that there's a particular version that makes snapshots more safe to ship release builds with @Fishrock123 do you remember the context of this? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. They are fixed in all io.js versions, but not 0.12, is my understanding. See this maybe: nodejs/node#1663 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for the heads up. nodejs/node#1631 (comment) doesn't seem to mention a specific v8 version where this was fixed. It probably boils down to calling v8::V8::SetEntropySource() at startup? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @orangemocha I'll play the devil's advocate here :) I'm concerned about the impact of this change for Node.js embedders who might rely on the performance improvement of snapshots being enabled by default. If we change the default build behavior, it might lead a significant performance drop for them. So even though disabling snapshots by default makes it easier for the build process, technically I guess that is a breaking change. Basically I just want us to be mindful of that use case while considering this change. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @misterdjules : do you build releases with snapshots or without? I'd argue that the default should be in line with how releases are built. But if that doesn't work, we could add a configure-for-ci parameter to configure.py. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
No doubt about that, it's really the impact of changing the behavior of the default build for v0.10 and v0.12 users who build node binaries themselves that I'm wondering about.
I would prefer this approach for v0.10 and v0.12, although I would pick a different option name. We use |
||
rm -rf out/deps out/Release | ||
$(PYTHON) ./configure --download=all --with-intl=small-icu \ | ||
--without-snapshot --dest-cpu=ia32 --tag=$(TAG) | ||
--dest-cpu=ia32 --tag=$(TAG) | ||
$(MAKE) install V=$(V) DESTDIR=$(PKGDIR)/32 | ||
rm -rf out/deps out/Release | ||
$(PYTHON) ./configure --download=all --with-intl=small-icu \ | ||
--without-snapshot --dest-cpu=x64 --tag=$(TAG) | ||
--dest-cpu=x64 --tag=$(TAG) | ||
$(MAKE) install V=$(V) DESTDIR=$(PKGDIR) | ||
SIGN="$(APP_SIGN)" PKGDIR="$(PKGDIR)" bash tools/osx-codesign.sh | ||
lipo $(PKGDIR)/32/usr/local/bin/node \ | ||
|
@@ -343,7 +346,7 @@ $(BINARYTAR): release-only | |
rm -rf $(BINARYNAME) | ||
rm -rf out/deps out/Release | ||
$(PYTHON) ./configure --prefix=/ --download=all --with-intl=small-icu \ | ||
--without-snapshot --dest-cpu=$(DESTCPU) --tag=$(TAG) $(CONFIG_FLAGS) | ||
--dest-cpu=$(DESTCPU) --tag=$(TAG) $(CONFIG_FLAGS) | ||
$(MAKE) install DESTDIR=$(BINARYNAME) V=$(V) PORTABLE=1 | ||
cp README.md $(BINARYNAME) | ||
cp LICENSE $(BINARYNAME) | ||
|
@@ -356,7 +359,7 @@ binary: $(BINARYTAR) | |
|
||
$(PKGSRC): release-only | ||
rm -rf dist out | ||
$(PYTHON) configure --prefix=/ --without-snapshot --download=all \ | ||
$(PYTHON) configure --prefix=/ --download=all \ | ||
--with-intl=small-icu --dest-cpu=$(DESTCPU) --tag=$(TAG) \ | ||
$(CONFIG_FLAGS) | ||
$(MAKE) install DESTDIR=dist | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -292,11 +292,16 @@ parser.add_option('--without-perfctr', | |
dest='without_perfctr', | ||
help='build without performance counters') | ||
|
||
parser.add_option('--with-snapshot', | ||
action='store_true', | ||
dest='with_snapshot', | ||
help=optparse.SUPPRESS_HELP) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. will fix |
||
|
||
# Dummy option for backwards compatibility. | ||
parser.add_option('--without-snapshot', | ||
action='store_true', | ||
dest='without_snapshot', | ||
help='build without snapshotting V8 libraries. You might want to set' | ||
' this for cross-compiling. [Default: False]') | ||
dest='unused_without_snapshot', | ||
help=optparse.SUPPRESS_HELP) | ||
|
||
parser.add_option('--without-ssl', | ||
action='store_true', | ||
|
@@ -323,6 +328,12 @@ parser.add_option('--xcode', | |
# set up auto-download list | ||
auto_downloads = nodedownload.parse(options.download_list) | ||
|
||
|
||
def warn(msg): | ||
prefix = '\033[1m\033[91mWARNING\033[0m' if os.isatty(1) else 'WARNING' | ||
print('%s: %s' % (prefix, msg)) | ||
|
||
|
||
def b(value): | ||
"""Returns the string 'true' if value is truthy, 'false' otherwise.""" | ||
if value: | ||
|
@@ -515,7 +526,7 @@ def configure_node(o): | |
o['variables']['host_arch'] = host_arch | ||
o['variables']['target_arch'] = target_arch | ||
|
||
if target_arch != host_arch and not options.without_snapshot: | ||
if target_arch != host_arch and options.with_snapshot: | ||
o['variables']['want_separate_host_toolset'] = 1 | ||
else: | ||
o['variables']['want_separate_host_toolset'] = 0 | ||
|
@@ -651,7 +662,7 @@ def configure_v8(o): | |
o['variables']['v8_no_strict_aliasing'] = 1 # Work around compiler bugs. | ||
o['variables']['v8_optimized_debug'] = 0 # Compile with -O0 in debug builds. | ||
o['variables']['v8_random_seed'] = 0 # Use a random seed for hash tables. | ||
o['variables']['v8_use_snapshot'] = b(not options.without_snapshot) | ||
o['variables']['v8_use_snapshot'] = b(options.with_snapshot) | ||
|
||
# assume shared_v8 if one of these is set? | ||
if options.shared_v8_libpath: | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,11 +17,11 @@ set msiplatform=x86 | |
set target=Build | ||
set target_arch=ia32 | ||
set debug_arg= | ||
set nosnapshot_arg= | ||
set snapshot_arg= | ||
set noprojgen= | ||
set nobuild= | ||
set nosign= | ||
set nosnapshot= | ||
set snapshot= | ||
set test= | ||
set test_args= | ||
set msi= | ||
|
@@ -50,7 +50,7 @@ if /i "%1"=="x64" set target_arch=x64&goto arg-ok | |
if /i "%1"=="noprojgen" set noprojgen=1&goto arg-ok | ||
if /i "%1"=="nobuild" set nobuild=1&goto arg-ok | ||
if /i "%1"=="nosign" set nosign=1&goto arg-ok | ||
if /i "%1"=="nosnapshot" set nosnapshot=1&goto arg-ok | ||
if /i "%1"=="snapshot" set snapshot=1&goto arg-ok | ||
if /i "%1"=="noetw" set noetw=1&goto arg-ok | ||
if /i "%1"=="noperfctr" set noperfctr=1&goto arg-ok | ||
if /i "%1"=="licensertf" set licensertf=1&goto arg-ok | ||
|
@@ -61,7 +61,8 @@ if /i "%1"=="test-simple" set test=test-simple&goto arg-ok | |
if /i "%1"=="test-message" set test=test-message&goto arg-ok | ||
if /i "%1"=="test-gc" set test=test-gc&set buildnodeweak=1&goto arg-ok | ||
if /i "%1"=="test-all" set test=test-all&set buildnodeweak=1&goto arg-ok | ||
if /i "%1"=="test" set test=test&goto arg-ok | ||
if /i "%1"=="test-ci" set test=test-ci&goto arg-ok | ||
if /i "%1"=="test" set test=test&set jslint=1&goto arg-ok | ||
@rem Include small-icu support with MSI installer | ||
if /i "%1"=="msi" set msi=1&set licensertf=1&set download_arg="--download=all"&set i18n_arg=small-icu&goto arg-ok | ||
if /i "%1"=="upload" set upload=1&goto arg-ok | ||
|
@@ -81,10 +82,9 @@ goto next-arg | |
|
||
:args-done | ||
if defined upload goto upload | ||
if defined jslint goto jslint | ||
|
||
if defined build_release ( | ||
set nosnapshot=1 | ||
set snapshot= | ||
set config=Release | ||
set msi=1 | ||
set licensertf=1 | ||
|
@@ -94,7 +94,7 @@ if defined build_release ( | |
|
||
if "%config%"=="Debug" set debug_arg=--debug | ||
if "%target_arch%"=="x64" set msiplatform=x64 | ||
if defined nosnapshot set nosnapshot_arg=--without-snapshot | ||
if defined snapshot set snapshot_arg=--with-snapshot | ||
if defined noetw set noetw_arg=--without-etw& set noetw_msi_arg=/p:NoETW=1 | ||
if defined noperfctr set noperfctr_arg=--without-perfctr& set noperfctr_msi_arg=/p:NoPerfCtr=1 | ||
|
||
|
@@ -151,7 +151,7 @@ goto exit | |
if defined noprojgen goto msbuild | ||
|
||
@rem Generate the VS project. | ||
python configure %download_arg% %i18n_arg% %debug_arg% %nosnapshot_arg% %noetw_arg% %noperfctr_arg% --dest-cpu=%target_arch% --tag=%TAG% | ||
python configure %download_arg% %i18n_arg% %debug_arg% %snapshot_arg% %noetw_arg% %noperfctr_arg% --dest-cpu=%target_arch% --tag=%TAG% | ||
if errorlevel 1 goto create-msvs-files-failed | ||
if not exist node.sln goto create-msvs-files-failed | ||
echo Project files generated. | ||
|
@@ -202,7 +202,11 @@ if "%test%"=="" goto exit | |
if "%config%"=="Debug" set test_args=--mode=debug | ||
if "%config%"=="Release" set test_args=--mode=release | ||
|
||
set test_args=%test_args% --arch=%target_arch% | ||
|
||
|
||
if "%test%"=="test" set test_args=%test_args% simple message | ||
if "%test%"=="test-ci" set test_args=%test_args% -p tap --logfile test.tap simple message internet | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @orangemocha Do we also want to pass |
||
if "%test%"=="test-internet" set test_args=%test_args% internet | ||
if "%test%"=="test-pummel" set test_args=%test_args% pummel | ||
if "%test%"=="test-simple" set test_args=%test_args% simple | ||
|
@@ -224,7 +228,7 @@ goto exit | |
:run-tests | ||
echo running 'python tools/test.py %test_args%' | ||
python tools/test.py %test_args% | ||
if "%test%"=="test" goto jslint | ||
if defined jslint goto jslint | ||
goto exit | ||
|
||
:create-msvs-files-failed | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps add an extra space to avoid confusion:
-p tap
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@orangemocha Should we pass
--flaky-tests=dontcare
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jbergstroem : will fix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@misterdjules : I haven't gotten to that part yet. I was planning to make those changes in a separate PR, but I might as well leave this one open and some commits for the node-accept-pull-request job.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good, either works for me.