Project

General

Profile

Bug #11697

test/dtrace failure on Solaris 10

Added by ngoto (Naohisa Goto) over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
[ruby-core:71504]

Description

test/dtrace fails on Solaris 10 as follows.

Ruby (64-bit) compiled by using Oracle Solaris Studio 12.3 cc with "-xO3" optimization:

$ SUDO=sudo ruby test/runner.rb test/dtrace
Run options:

# Running tests:

[26/26] DTrace::TestStringProbes#test_object_create_start_string_lit = 1.5
  1) Failure:
DTrace::TestStringProbes#test_object_create_start_string_lit [/XXXXX-52420/test/dtrace/test_string.rb:10]:
<["String"]> expected but was
<[]>.

Finished tests in 33.513504s, 0.7758 tests/s, 6.2960 assertions/s.
26 tests, 211 assertions, 1 failures, 0 errors, 0 skips

ruby -v: ruby 2.3.0dev (2015-11-01) [sparc64-solaris2.10]

Ruby (64-bit) compiled by using Solaris Studio 12.3 cc without optimization (with "-xO0") :

$ SUDO=sudo ruby test/runner.rb test/dtrace
Run options: 

# Running tests:

[ 3/26] DTrace::TestCMethod#test_entry = 1.77 s                  
  1) Failure:
DTrace::TestCMethod#test_entry [/XXXXX-52250/test/dtrace/test_cmethod.rb:18]:
<1> expected but was
<0>.

Finished tests in 40.703063s, 0.6388 tests/s, 5.2330 assertions/s.                   
26 tests, 213 assertions, 1 failures, 0 errors, 0 skips

ruby -v: ruby 2.3.0dev (2015-10-24) [sparc64-solaris2.10]

It seems that the failure is due to overflowing of dtrace's trace buffer.
On Solaris, the default buffer size is 4MB.
The failure does not happen when increasing the buffer size to 8MB (calling dtrace with "-b 8m" option)

--- test/dtrace/helper.rb.ORIG~ 2014-11-19 23:15:23.909272000 +0900
+++ test/dtrace/helper.rb       2015-11-16 21:03:35.411936000 +0900
@@ -26,7 +26,7 @@
       d_path  = d.path
       rb_path = rb.path

-      cmd = ["dtrace", "-q", "-s", d_path, "-c", "#{EnvUtil.rubybin} -I#{INCLUDE} #{rb_path}"]
+      cmd = ["dtrace", "-b", "8m", "-q", "-s", d_path, "-c", "#{EnvUtil.rubybin} -I#{INCLUDE} #{rb_path}"]
       if sudo = @@sudo
         [RbConfig::CONFIG["LIBPATHENV"], "RUBY", "RUBYOPT"].each do |name|
           if name and val = ENV[name]

Associated revisions

Revision 7506498f
Added by ngoto (Naohisa Goto) over 3 years ago

  • test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52597 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 52597
Added by ngoto (Naohisa Goto) over 3 years ago

  • test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

Revision 52597
Added by ngoto (Naohisa Goto) over 3 years ago

  • test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

Revision 52597
Added by ngoto (Naohisa Goto) over 3 years ago

  • test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

Revision 52597
Added by ngoto (Naohisa Goto) over 3 years ago

  • test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

Revision 52597
Added by ngoto (Naohisa Goto) over 3 years ago

  • test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

History

#1

Updated by ngoto (Naohisa Goto) over 3 years ago

  • Status changed from Open to Closed

Applied in changeset r52597.


  • test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

Also available in: Atom PDF