Recall that Fenix optimizations (a.k.a use Windows API to make `File.expand_path` much faster) must be explicitly enabled similar to `set RUBYOPT=-rfenix/replace` or `ruby -rfenix/replace ...`
Notable updates from previous build:
* Yura's new Hash optimizations and updates to cached $LOAD_PATH and sorted $LOADED_FEATURES
* 1.9.3 backports as of ruby_1_9_3@34386
* OpenSSL 1.0.0g
* RubyGems 1.8.15
* Built with MinGW GCC 4.6.2 toolchain (untested on WinXP SP3)
Built and tested on:
* Windows 7 32bit/MinGW 4.6.2
* Arch 3.2.2 32bit/GCC 4.6.2
* FreeBSD 9.0 32bit/GCC 4.2.1 (build OK but false test failures; clang 3.0 build failures)
=== Build Summary ===
git co -b tcs-ruby_1_9_3 codeshop/ruby_1_9_3
git rebase winstat/ruby_1_9_3
git rebase winio/ruby_1_9_3
git rebase st_optimize/ruby_1_9_3
git rebase fileload-ok/ruby_1_9_3
git rebase cached-lp/ruby_1_9_3
git rebase sorted-lf/ruby_1_9_3
git rebase fenix/ruby_1_9_3
# fix `load.c:rb_get_expanded_load_path` merge conflict, `git rebase --continue`
# replace missed `rb_file_expand_path` in `load.c` and `ruby.c`
rake ruby19 local=C:\Users\Jon\Documents\RubyDev\ruby-git dkver=mingw-32-4.6.2
# add fenix artifacts (MinGW v4.6.2) to sandboxed `site-ruby/1.9.1/i386-msvcrt/`
RUBYOPT="-rfenix/replace" make test-all TESTS='openssl fiddle psych zlib io json mkmf pathname stringio erb fileutils ruby/test_io.rb ruby/test_io_m17n.rb ruby/test_file.rb'
RUBYOPT="-rfenix/replace" make test
=== Rails 3.2.1 (Win7 32bit) Startup Performance ===
# `rails new rails-empty`
C:\rails-empty>ruby --version
ruby 1.9.3p0 (2011-11-08 revision 33661) [i386-mingw32]
C:\rails-empty>timer ruby script\rails r "p $LOAD_PATH.size, $LOADED_FEATURES.size"
59
738
real 8.439
system 5.928
user 2.386
# `rails new rails-empty -d jdbcsqlite3`
C:\rails-empty>jruby --version
jruby 1.6.5.1 (ruby-1.8.7-p330) (2011-12-27 1bf37c2) (Java HotSpot(TM) Client VM 1.7.0_02) [Windows 7-x86-java]
C:\rails-empty>timer jruby script\rails r "p $LOAD_PATH.size, $LOADED_FEATURES.size"
60
738
real 7.332
system 1.778
user 6.318
# `rails new rails-empty`
C:\rails-empty>ruby --version
tcs-ruby 1.9.3p28 (2012-01-28, TCS patched 2012-01-30) [i386-mingw32]
C:\rails-empty>timer ruby script\rails r "p $LOAD_PATH.size, $LOADED_FEATURES.size"
59
738
real 3.775
system 2.652
user 1.107
C:\rails-empty>timer ruby -rfenix/replace script\rails r "p $LOAD_PATH.size, $LOADED_FEATURES.size"
59
740
real 2.121
system 0.967
user 1.107
=== Large File Read (Win7 32bit) Microbenchmark ===
C:\projects\measurements-git>pik run rci bench core_rd_filelines_lf
jruby 1.6.5.1 (ruby-1.8.7-p330) (2011-12-27 1bf37c2) (Java HotSpot(TM) Client VM 1.7.0_02) [Windows 7-x86-java]
Rehearsal --------------------------------------------------------
core_rd_filelines_lf 7.878000 0.000000 7.878000 ( 7.847000)
----------------------------------------------- total: 7.878000sec
user system total real
core_rd_filelines_lf 7.816000 0.000000 7.816000 ( 7.816000)
ruby 1.8.7 (2011-12-28 patchlevel 357) [i386-mingw32]
Rehearsal --------------------------------------------------------
core_rd_filelines_lf 1.716000 0.203000 1.919000 ( 1.918804)
----------------------------------------------- total: 1.919000sec
user system total real
core_rd_filelines_lf 1.732000 0.171000 1.903000 ( 1.903203)
ruby 1.9.2p290 (2011-07-09) [i386-mingw32]
Rehearsal --------------------------------------------------------
core_rd_filelines_lf 17.472000 0.063000 17.535000 ( 17.534431)
---------------------------------------------- total: 17.535000sec
user system total real
core_rd_filelines_lf 17.519000 0.078000 17.597000 ( 17.628031)
ruby 1.9.3p0 (2011-11-08 revision 33661) [i386-mingw32]
Rehearsal --------------------------------------------------------
core_rd_filelines_lf 17.612000 0.062000 17.674000 ( 17.690431)
---------------------------------------------- total: 17.674000sec
user system total real
core_rd_filelines_lf 17.753000 0.016000 17.769000 ( 17.784032)
tcs-ruby 1.9.3p28 (2012-01-28, TCS patched 2012-01-30) [i386-mingw32]
Rehearsal --------------------------------------------------------
core_rd_filelines_lf 1.155000 0.125000 1.280000 ( 1.279202)
----------------------------------------------- total: 1.280000sec
user system total real
core_rd_filelines_lf 1.170000 0.094000 1.264000 ( 1.263602)
ruby 2.0.0dev (2012-01-28 trunk 34390) [i386-mingw32]
Rehearsal --------------------------------------------------------
core_rd_filelines_lf 1.185000 0.078000 1.263000 ( 1.263603)
----------------------------------------------- total: 1.263000sec
user system total real
core_rd_filelines_lf 1.155000 0.109000 1.264000 ( 1.263602)
Jon
---
Fail fast. Fail often. Fail publicly. Learn. Adapt. Repeat.
http://thecodeshop.github.com | http://jonforums.github.com/
twitter: @jonforums
I like it.
Since I rebased all your commits from `st_optimize/ruby_1_9_3`, `cached_lp/ruby_1_9_3`, and `sorted_lf/ruby_1_9_3` onto `tcs-ruby_1_9_3` can rvm and rbenv use the `tcs-ruby_1_9_3` branch as-is or do we need to do something else? (I'm a minimal rvm user and haven't yet looked at rbenv.)
My only concern is that since the `tcs-ruby_1_9_3` branch will likely be forced everytime I do a release, the rebasing could cause downstream problems.
What's the easiest and most maintainable way for us to work with rvm and rbenv for releases?
Jon
I use rvm on my Arch VM and will install rbenv on my FreeBSD VM a bit later...reading their doco...
This seems to work for me on my FreeBSD 9.0 VM with rbenv. I will update the FAQ with rvm info after testing on my Arch VM.
https://github.com/thecodeshop/ruby/wiki/FAQ#wiki-rbenv
devil% uname -opr
FreeBSD 9.0-RELEASE i386
devil% rbenv global
system
devil% rbenv versions
tcs-ruby_1.9.3-p28
devil% rbenv which ruby
/usr/local/bin/ruby
devil% rbenv shell tcs-ruby_1.9.3-p28
devil% rbenv which ruby
/home/jon/.rbenv/versions/tcs-ruby_1.9.3-p28/bin/ruby
devil% ruby -ve 'puts "Hello from TCS Ruby!"'
tcs-ruby 1.9.3p28 (2012-01-28, TCS patched 2012-01-30) [i386-freebsd9.0]
Hello from TCS Ruby!
But I think the replacements for Fenix on Windows could degrade performance on *nix so I'll #ifndef the `tcs-ruby_1_9_3` and `fenix/ruby_1_9_3` branches unless I hear differently from anyone.
https://github.com/thecodeshop/ruby/commit/22277c0b5c524da4583895a3c9053914b889fd4c
Feel free to update the FAQ entry if needed.
Jon
Awesome...looking forward to testing in my Win7 (MinGW and Windows SDK), Arch, and FreeBSD environments.
When tweaking `tcs-ruby_1_9_3`, please update the TCS datestamps https://github.com/thecodeshop/ruby/commit/b29f5d410af004ccef475f91c0ef70ffd25c7707 just in case someone runs into issues and posts at the ML or repo.
What OS/toolchains did you test (`make test && make test-all` ??) the new mods on?
Thanks,
Jon
:)
No build/test failures with...
== FreeBSD 9.0 VM/GCC 4.2.1 ==
../configure --enable-shared --disable-install-doc
make
make test
make test-all TESTS='openssl fiddle psych zlib io json mkmf pathname stringio erb fileutils ruby/test_io.rb ruby/test_io_m17n.rb ruby/test_file.rb'
== Win7/Windows SDK 7.1 (no deps) ==
..\win32\configure.bat --disable-install-doc --disable-win95
nmake
nmake test
nmake test-all TESTS="mkmf pathname stringio fileutils ruby/test_io.rb ruby/test_io_m17n.rb ruby/test_file.rb"