[#11680] fork_and_kill_other_threads — "NAKAMURA, Hiroshi" <nakahiro@...>

なひです。[ruby-list:26165]からもって来ました。

27 messages 2000/12/02
[#11681] Re: fork_and_kill_other_threads — Masatoshi SEKI <m_seki@...> 2000/12/02

[#11682] Re: fork_and_kill_other_threads — matz@... (Yukihiro Matsumoto) 2000/12/02

まつもと ゆきひろです

[#11685] Re: fork_and_kill_other_threads — nobu.nakada@... 2000/12/03

なかだです。

[#11687] Re: fork_and_kill_other_threads — matz@... (Yukihiro Matsumoto) 2000/12/03

まつもと ゆきひろです

[#11708] Re: fork_and_kill_other_threads — Kazuhiro NISHIYAMA <zn@...> 2000/12/06

On Sun, 3 Dec 2000 23:33:41 +0900

[#11709] Re: fork_and_kill_other_threads — matz@... (Yukihiro Matsumoto) 2000/12/06

まつもと ゆきひろです

[#11710] Re: fork_and_kill_other_threads — "NAKAMURA, Hiroshi" <nakahiro@...> 2000/12/06

なひです。

[#11713] Re: fork_and_kill_other_threads — matz@... (Yukihiro Matsumoto) 2000/12/06

まつもと ゆきひろです

[#11716] Re: fork_and_kill_other_threads — "NAKAMURA, Hiroshi" <nakahiro@...> 2000/12/06

なひです。

[#11718] Re: fork_and_kill_other_threads — matz@... (Yukihiro Matsumoto) 2000/12/06

まつもと ゆきひろです

[#11722] Re: fork_and_kill_other_threads — "NAKAMURA, Hiroshi" <nakahiro@...> 2000/12/07

なひです。

[#11733] Ruby I18N 改め M17N — とみたまさひろ <tommy@...>

とみたです。

17 messages 2000/12/07
[#11735] Re: Ruby I18N 改め M17N — matz@... (Yukihiro Matsumoto) 2000/12/08

まつもと ゆきひろです

[#11751] Re: Ruby I18N 改め M17N — とみたまさひろ <tommy@...> 2000/12/13

とみたです。

[#11752] Re: Ruby I18N 改め M17N — matz@... (Yukihiro Matsumoto) 2000/12/13

まつもと ゆきひろです

[#11789] mswin32 [Q & patch] mkmf.rb — "U.Nakamura" <usa@...>

こんにちは、なかむら(う)です。

14 messages 2000/12/18
[#11790] Re: mswin32 [Q & patch] mkmf.rb — "Nobuyoshi.Nakada" <nobu.nakada@...> 2000/12/19

なかだです。

[#11848] Where'd all the Ruby's history gone? — "Akinori MUSHA" <knu@...>

 さっき気付いたんですが、 Ruby のレポジトリから過去分がごっそり

27 messages 2000/12/25
[#11853] Re: Where'd all the Ruby's history gone? — matz@... (Yukihiro Matsumoto) 2000/12/26

まつもと ゆきひろです

[#11861] Re: Where'd all the Ruby's history gone? — Kazuhiro NISHIYAMA <zn@...> 2000/12/26

On Tue, 26 Dec 2000 14:58:07 +0900

[#11862] Re: Where'd all the Ruby's history gone? — matz@... (Yukihiro Matsumoto) 2000/12/26

まつもと ゆきひろです

[#11869] Re: Where'd all the Ruby's history gone? — "Akinori MUSHA" <knu@...> 2000/12/26

At Tue, 26 Dec 2000 17:44:57 +0900,

[#11894] Re: Where'd all the Ruby's history gone? — Kazuhiro NISHIYAMA <zn@...> 2000/12/29

On Tue, 26 Dec 2000 21:24:19 +0900

[#11895] Re: Where'd all the Ruby's history gone? — "Akinori MUSHA" <knu@...> 2000/12/29

At Fri, 29 Dec 2000 18:56:03 +0900,

[#11896] Re: Where'd all the Ruby's history gone? — Kazuhiro NISHIYAMA <zn@...> 2000/12/29

On Fri, 29 Dec 2000 19:07:12 +0900

[#11852] local variable extent problem? — Tanaka Akira <akr@...17n.org>

どうも、Ruby のバグのような気がするものを見つけたのですが、もしかした

21 messages 2000/12/26
[#11855] Re: local variable extent problem? — matz@... (Yukihiro Matsumoto) 2000/12/26

まつもと ゆきひろです

[#11857] Re: local variable extent problem? — Tanaka Akira <akr@...17n.org> 2000/12/26

In article <977817486.100168.31162.nullmailer@ev.netlab.zetabits.com>,

[#11859] Re: local variable extent problem? — matz@... (Yukihiro Matsumoto) 2000/12/26

まつもと ゆきひろです

[#11860] Re: local variable extent problem? — Tanaka Akira <akr@...17n.org> 2000/12/26

In article <977819010.870991.31953.nullmailer@ev.netlab.zetabits.com>,

[#11863] Re: local variable extent problem? — matz@... (Yukihiro Matsumoto) 2000/12/26

まつもと ゆきひろです

[#11865] Re: local variable extent problem? — "Akinori MUSHA" <knu@...> 2000/12/26

At Tue, 26 Dec 2000 17:50:11 +0900,

[#11874] Re: local variable extent problem? — matz@... (Yukihiro Matsumoto) 2000/12/26

まつもと ゆきひろです

[ruby-dev:11785] [Patch] tracer.rb following ruby/1.6 debug API

From: "NAKAMURA, Hiroshi" <nakahiro@...>
Date: 2000-12-18 14:10:45 UTC
List: ruby-dev #11785
なひです。

> From: Yukihiro Matsumoto
> Sent: Friday, December 08, 2000 10:22 AM

> |> |1-a. いずれかのthreadがbpなどで停止すると、全threadが止まる。
> |> |1-b. いずれかのthreadがbpなどで停止すると、そのthreadのみが止まる。
> |> |2. thread stopすると、指定されたthreadが止まる。
> |> |3. thread resumeすると、指定されたthreadが再開する。
> |> |
> |> |とかですかね?ちょっと排他制御が難しくなりそう。。。
> |> 
> |> 2,3はその通りです。1は1-bが望ましいと思ってます。
> |
> |A) 1-aが欲しいシチュエーションはどうしましょうか。
> |「何か起こった時」の状態を検査したい場合、
> |動きつづけられると困る場合もあると思います。
> 
> ああ、そうか。たとえば1-aで、次の再開(nとかcとか)で全部が動
> きだすとかが可能であればその方が良いかもしれませんね。

の流れでdebug.rbをいじっていて、
ついでにtracer.rbも変更したくなったのでpatchです。
1.6のdebug APIに対応して、表示される情報量を増やしました(klass)。
従来c-call/c-returnの時はろくな情報が表示されてなかったのですが、
少しはわかりやすくなるかな?

「これでは情報量が多すぎる」という場合もあると思うので、
そのうちtrace levelみたいなのを導入したいです。誰か?

--- /usr/local/lib/ruby/1.6/tracer.rb	Wed Oct 11 19:42:22 2000
+++ ./tracer.rb	Mon Dec 18 22:35:57 2000
@@ -32,5 +32,8 @@ class Tracer
     "return" => "<",
     "class" => "C",
-    "end" => "E"}
+    "end" => "E",
+    "c-call" => ">",
+    "c-return" => "<",
+  }
   
   def initialize
@@ -60,6 +63,6 @@ class Tracer
       end
     else
-      set_trace_func proc{|event, file, line, id, binding, klass|
-	trace_func event, file, line, id, binding
+      set_trace_func proc{|event, file, line, id, binding, klass, *rest|
+	trace_func event, file, line, id, binding, klass
       }
       stdout.print "Trace on\n" if Tracer.verbose?
@@ -86,5 +89,4 @@ class Tracer
 
     unless list = LINES__[file]
-#      stdout.print file if $DEBUG
       begin
 	f = open(file)
@@ -113,19 +115,19 @@ class Tracer
   end
   
-  def trace_func(event, file, line, id, binding)
+  def trace_func(event, file, line, id, binding, klass)
     return if file == MY_FILE_NAME
-    #stdout.printf "Th: %s\n", Thread.current.inspect
     
     for p in @filters
-      return unless p.call event, file, line, id, binding
+      return unless p.call event, file, line, id, binding, klass
     end
     
     Thread.critical = true
-    stdout.printf("#%d:%s:%d:%s: %s",
-	   get_thread_no,
-	   file,
-	   line,
-	   EVENT_SYMBOL[event],
-	   get_line(file, line))
+    stdout.printf("#%d:%s:%d:%s:%s: %s",
+      get_thread_no,
+      file,
+      line,
+      klass || '',
+      EVENT_SYMBOL[event],
+      get_line(file, line))
     Thread.critical = false
   end

In This Thread