|
27 | 27 |
|
28 | 28 | JDEBUG_PORT = 51819
|
29 | 29 | JDEBUG = "--vm.agentlib:jdwp=transport=dt_socket,server=y,address=#{JDEBUG_PORT},suspend=y"
|
30 |
| -JEXCEPTION = "--exceptions.print_uncaught_java=true" |
31 | 30 | METRICS_REPS = Integer(ENV["TRUFFLERUBY_METRICS_REPS"] || 10)
|
32 | 31 | DEFAULT_PROFILE_OPTIONS = %w[--cpusampler --cpusampler.SampleInternal=true --cpusampler.Mode=roots --cpusampler.Output=json]
|
33 | 32 |
|
@@ -517,7 +516,7 @@ def help
|
517 | 516 | cexts build only the C extensions (part of "jt build")
|
518 | 517 | graalvm [--graal] [--native] build a minimal JVM-only GraalVM containing only TruffleRuby
|
519 | 518 | --graal include graal compiler in the build
|
520 |
| - --native build native ruby image as well |
| 519 | + --native build native ruby image as well |
521 | 520 | native [--no-sulong] [--no-jvmci] [--no-sforceimports] [--no-tools] [extra mx image options]
|
522 | 521 | build a native image of TruffleRuby (--no-jvmci to use the system Java)
|
523 | 522 | (--no-tools to exclude chromeinspector and profiler)
|
@@ -582,8 +581,8 @@ def help
|
582 | 581 | jt metrics time ... how long does it take to run a command, broken down into different phases
|
583 | 582 | jt benchmark [options] args... run benchmark-interface (implies --graal)
|
584 | 583 | --no-graal don't imply --graal
|
585 |
| - JT_BENCHMARK_RUBY=ruby benchmark some other Ruby, like MRI |
586 |
| - note that to run most MRI benchmarks, you should translate them first with normal |
| 584 | + JT_BENCHMARK_RUBY=ruby benchmark some other Ruby, like MRI |
| 585 | + note that to run most MRI benchmarks, you should translate them first with normal |
587 | 586 | Ruby and cache the result, such as benchmark bench/mri/bm_vm1_not.rb --cache
|
588 | 587 | jt benchmark bench/mri/bm_vm1_not.rb --use-cache
|
589 | 588 | jt profile profiles an application, including the TruffleRuby runtime, and generates a flamegraph
|
@@ -724,9 +723,9 @@ def run_ruby(*args)
|
724 | 723 | when '--jdebug'
|
725 | 724 | vm_args << JDEBUG
|
726 | 725 | when '--jexception', '--jexceptions'
|
727 |
| - vm_args << '--experimental-options' << JEXCEPTION |
| 726 | + vm_args << '--experimental-options' << '--exceptions.print_uncaught_java=true' |
728 | 727 | when '--server'
|
729 |
| - vm_args += %w[--instrumentation_server_port=8080] |
| 728 | + vm_args << '--experimental-options' << '--instrumentation_server_port=8080' |
730 | 729 | when '--infopoints'
|
731 | 730 | vm_args << "--vm.XX:+UnlockDiagnosticVMOptions" << "--vm.XX:+DebugNonSafepoints"
|
732 | 731 | vm_args << "--vm.Dgraal.TruffleEnableInfopoints=true"
|
@@ -1038,7 +1037,7 @@ def retag(*args)
|
1038 | 1037 | def test_compiler(*args)
|
1039 | 1038 | env = {}
|
1040 | 1039 |
|
1041 |
| - env['TRUFFLERUBYOPT'] = [*ENV['TRUFFLERUBYOPT'], '--exceptions.print_java=true'].join(' ') |
| 1040 | + env['TRUFFLERUBYOPT'] = [*ENV['TRUFFLERUBYOPT'], '--experimental-options', '--exceptions.print_java=true'].join(' ') |
1042 | 1041 |
|
1043 | 1042 | Dir["#{TRUFFLERUBY_DIR}/test/truffle/compiler/*.sh"].sort.each do |test_script|
|
1044 | 1043 | if args.empty? or args.include?(File.basename(test_script, ".*"))
|
@@ -1245,12 +1244,17 @@ def test_bundle(*args)
|
1245 | 1244 | # add bin from gem_home to PATH
|
1246 | 1245 | 'PATH' => ["#{gem_home}/bin", ENV['PATH']].join(File::PATH_SEPARATOR))
|
1247 | 1246 |
|
| 1247 | + options = [ |
| 1248 | + '--experimental-options', |
| 1249 | + '--exceptions.print_java=true', |
| 1250 | + ] |
| 1251 | + |
1248 | 1252 | gemserver_source = %w[--clear-sources --source http://localhost:8808]
|
1249 | 1253 |
|
1250 |
| - run_ruby(environment, *args, '--exceptions.print_java=true', |
| 1254 | + run_ruby(environment, *args, *options, |
1251 | 1255 | '-Sbundle', 'install', '-V', *install_flags)
|
1252 |
| - |
1253 |
| - run_ruby(environment, *args, '--exceptions.print_java=true', |
| 1256 | + |
| 1257 | + run_ruby(environment, *args, *options, |
1254 | 1258 | '-Sbundle', 'exec', '-V', 'rake')
|
1255 | 1259 | end
|
1256 | 1260 | ensure
|
@@ -1324,7 +1328,7 @@ def test_specs(command, *args)
|
1324 | 1328 | end
|
1325 | 1329 |
|
1326 | 1330 | if args.delete('--jexception') || args.delete('--jexceptions')
|
1327 |
| - options << "-T#{JEXCEPTION}" |
| 1331 | + options << "-T--experimental-options" << "-T--exceptions.print_uncaught_java=true" |
1328 | 1332 | end
|
1329 | 1333 |
|
1330 | 1334 | if args.delete('--truffle-formatter')
|
@@ -2351,7 +2355,7 @@ def dockerfile(*args)
|
2351 | 2355 | end
|
2352 | 2356 |
|
2353 | 2357 | configs.each do |config|
|
2354 |
| - lines.push "RUN " + setup_env["ruby #{config} --vm.Dgraal.TruffleCompilationExceptionsAreThrown=true --vm.Dgraal.TruffleIterativePartialEscape=true --basic_ops.inline=false pe/pe.rb"] |
| 2358 | + lines.push "RUN " + setup_env["ruby #{config} --vm.Dgraal.TruffleCompilationExceptionsAreThrown=true --vm.Dgraal.TruffleIterativePartialEscape=true --experimental-options --basic_ops.inline=false pe/pe.rb"] |
2355 | 2359 | end
|
2356 | 2360 | end
|
2357 | 2361 |
|
|
0 commit comments