@@ -826,7 +826,7 @@ def help
826
826
Ruby and cache the result, such as benchmark bench/mri/bm_vm1_not.rb --cache
827
827
jt benchmark bench/mri/bm_vm1_not.rb --use-cache
828
828
jt profile profiles an application, including the TruffleRuby runtime, and generates a flamegraph
829
- jt graph [ruby options] [--method Object#foo] [--watch] [--no-simplify] file.rb
829
+ jt graph [ruby options] [--method Object#foo] [--watch] [--no-simplify] file.rb [-- seafoam options]
830
830
render a graph of Object#foo within file.rb
831
831
--describe describe the shape of the graph (linear, branches, loops, calls, deopts)
832
832
jt igv launches IdealGraphVisualizer
@@ -2045,6 +2045,7 @@ def graph(*args)
2045
2045
simplify = true
2046
2046
describe = false
2047
2047
json = false
2048
+ seafoam_args = [ ]
2048
2049
2049
2050
vm_args , remaining_args , _parsed_options = ruby_options ( { } , args )
2050
2051
args = remaining_args
@@ -2064,7 +2065,8 @@ def graph(*args)
2064
2065
when '--describe'
2065
2066
describe = true
2066
2067
when '--'
2067
- raise
2068
+ seafoam_args = args . dup
2069
+ args . clear
2068
2070
when /^-/
2069
2071
vm_args << arg
2070
2072
else
@@ -2132,7 +2134,7 @@ def graph(*args)
2132
2134
2133
2135
json_args = json ? %w[ --json ] : [ ]
2134
2136
action = describe ? 'describe' : 'render'
2135
- run_gem_test_pack_gem_or_install ( 'seafoam' , SEAFOAM_VERSION , *json_args , "#{ graph } :#{ n } " , action )
2137
+ run_gem_test_pack_gem_or_install ( 'seafoam' , SEAFOAM_VERSION , *json_args , "#{ graph } :#{ n } " , action , * seafoam_args )
2136
2138
2137
2139
break unless watch
2138
2140
puts # newline between runs
0 commit comments