[前][次][番号順一覧][スレッド一覧]

ruby-changes:40516

From: ngoto <ko1@a...>
Date: Mon, 16 Nov 2015 21:38:30 +0900 (JST)
Subject: [ruby-changes:40516] ngoto:r52597 (trunk): * test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer size is set as 8m on Solaris (default 4m). [Bug #11697]

ngoto	2015-11-16 21:38:09 +0900 (Mon, 16 Nov 2015)

  New Revision: 52597

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=52597

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

  Modified files:
    trunk/ChangeLog
    trunk/test/dtrace/helper.rb
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 52596)
+++ ChangeLog	(revision 52597)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Mon Nov 16 21:27:54 2015  Naohisa Goto  <ngotogenome@g...>
+
+	* test/dtrace/helper.rb (Dtrace::TestCase#trap_probe): dtrace buffer
+	  size is set as 8m on Solaris (default 4m). [Bug #11697]
+
 Mon Nov 16 18:21:52 2015  Nobuyoshi Nakada  <nobu@r...>
 
 	* object.c (rb_obj_dig): dig in nested structs too.
Index: test/dtrace/helper.rb
===================================================================
--- test/dtrace/helper.rb	(revision 52596)
+++ test/dtrace/helper.rb	(revision 52597)
@@ -26,7 +26,15 @@ module DTrace https://github.com/ruby/ruby/blob/trunk/test/dtrace/helper.rb#L26
       d_path  = d.path
       rb_path = rb.path
 
-      cmd = ["dtrace", "-q", "-s", d_path, "-c", "#{EnvUtil.rubybin} -I#{INCLUDE} #{rb_path}"]
+      case RUBY_PLATFORM
+      when /solaris/i
+        # increase bufsize to 8m (default 4m on Solaris)
+        cmd = [ "dtrace", "-b", "8m" ]
+      else
+        cmd = [ "dtrace" ]
+      end
+
+      cmd.concat [ "-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]

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]