Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: e6ca426fb003
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 85634145eb27
Choose a head ref
  • 5 commits
  • 10 files changed
  • 1 contributor

Commits on Dec 11, 2015

  1. [Truffle] Eclipse launcher: put everything on the BCP by default for …

    …faster loading.
    
    * About 25% faster for a hello world.
    eregon committed Dec 11, 2015
    Copy the full SHA
    8852a25 View commit details
  2. Copy the full SHA
    904c6b9 View commit details
  3. [Truffle] Fix Thread.handle_interrupt to make sure we do not forget t…

    …he unhandled interrupt.
    eregon committed Dec 11, 2015
    Copy the full SHA
    717c049 View commit details
  4. Copy the full SHA
    2e81d59 View commit details
  5. Copy the full SHA
    8563414 View commit details
3 changes: 0 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -82,9 +82,6 @@ matrix:
# dist: trusty
# group: edge
# jdk: oraclejdk9
allow_failures: # TODO: due MRI test imports from 2.2.3 - needs to be reviewed for truffle!
- env: PHASE='-Ptruffle-mri-tests'


branches:
only:
1 change: 1 addition & 0 deletions test/mri/excludes_truffle/TestFloat.rb
Original file line number Diff line number Diff line change
@@ -14,3 +14,4 @@
exclude :test_strtod, "needs investigation"
exclude :test_to_s, "needs investigation"
exclude :test_truncate, "needs investigation"
exclude :test_hash_0, "-0.0.hash is not == 0.0.hash currently"
2 changes: 2 additions & 0 deletions test/mri/excludes_truffle/TestMethod.rb
Original file line number Diff line number Diff line change
@@ -41,3 +41,5 @@
exclude :test_unlinked_method_entry_in_method_object_bug, "needs investigation"
exclude :test_visibility, "needs investigation"
exclude :test_caller_top_level, "needs investigation"
exclude :test_insecure_method, "needs investigation"
exclude :test_to_proc_binding, "needs investigation"
1 change: 1 addition & 0 deletions test/mri/excludes_truffle/TestRange.rb
Original file line number Diff line number Diff line change
@@ -15,3 +15,4 @@
exclude :test_range_bsearch_for_floats, "needs investigation"
exclude :test_range_numeric_string, "needs investigation"
exclude :test_size, "needs investigation"
exclude :test_eqq_time, "needs investigation"
2 changes: 2 additions & 0 deletions test/mri/excludes_truffle/TestSymbol.rb
Original file line number Diff line number Diff line change
@@ -4,3 +4,5 @@
exclude :test_symbol_encoding, "needs investigation"
exclude :test_symbol_gc_1, "needs investigation"
exclude :test_to_proc, "needs investigation"
exclude :test_hash_redefinition, "hangs"
exclude :test_symbol_fstr_leak, "hangs"
6 changes: 6 additions & 0 deletions test/mri/excludes_truffle/TestSyntax.rb
Original file line number Diff line number Diff line change
@@ -51,3 +51,9 @@
exclude :test_brace_block_after_blockcall_colon_with_arg, "needs investigation"
exclude :test_newline_in_block_parameters, "needs investigation"
exclude :test_warn_unreachable, "needs investigation"
exclude :test_bad_kwarg, "needs investigation"
exclude :test_do_block_in_lambda, "needs investigation"
exclude :test_keyword_self_reference, "needs investigation"
exclude :test_keyword_empty_splat, "needs investigation"
exclude :test_null_range_cmdarg, "needs investigation"
exclude :test_too_big_nth_ref, "needs investigation"
9 changes: 9 additions & 0 deletions test/mri/excludes_truffle/TestTimeExtension.rb
Original file line number Diff line number Diff line change
@@ -24,3 +24,12 @@
exclude :test_xmlschema_fraction, "needs investigation"
exclude :test_xmlschema_leap_second, "needs investigation"
exclude :test_zone_0000, "needs investigation"
exclude :test_iso8601, "needs investigation"
exclude :test_iso8601_alias, "needs investigation"
exclude :test_iso8601_encode, "needs investigation"
exclude :test_iso8601_nsec, "needs investigation"
exclude :test_strptime_s_N, "needs investigation"
exclude :test_xmlschema_alias, "needs investigation"
exclude :test_xmlschema_encode, "needs investigation"
exclude :test_xmlschema_nsec, "needs investigation"
exclude :test_iso8601_leap_second, "needs investigation"
9 changes: 9 additions & 0 deletions tool/jruby_eclipse
Original file line number Diff line number Diff line change
@@ -4,9 +4,12 @@

TRUFFLEJAR = "#{Dir.home}/.m2/repository/com/oracle/truffle/0.7/truffle-0.7.jar"
SNAKEYAMLJAR = "#{Dir.home}/.m2/repository/org/yaml/snakeyaml/1.14/snakeyaml-1.14.jar"
ANTLR4JAR = "#{Dir.home}/.m2/repository/org/antlr/antlr4-runtime/4.5/antlr4-runtime-4.5.jar"

JRUBY = File.expand_path('../..', __FILE__)

VERIFY_JRUBY = false

java = ENV["JAVACMD"] || "java"

java_flags = []
@@ -33,10 +36,16 @@ classpath << "#{JRUBY}/lib/jruby-stdlib-9.0.0.0-SNAPSHOT.jar"
if rest.include?('-X+T')
bootclasspath << TRUFFLEJAR
classpath << SNAKEYAMLJAR
classpath << ANTLR4JAR
classpath << "#{JRUBY}/truffle/build.eclipse"
java_flags << "-Djruby.truffle.core.load_path=#{JRUBY}/truffle/src/main/ruby"
end

unless VERIFY_JRUBY
bootclasspath += classpath
classpath.clear
end

args = [java]
args << "-Djffi.boot.library.path=#{JRUBY}/lib/jni"
args << "-Xbootclasspath/a:" + bootclasspath.join(':')
Original file line number Diff line number Diff line change
@@ -31,7 +31,7 @@ DynamicObjectFactory createThreadShape(DynamicObject logicalClass,

DynamicObject createThread(DynamicObjectFactory factory,
DynamicObject threadLocals,
InterruptMode interruptMode,
@Volatile InterruptMode interruptMode, // needs to be volatile for fibers implemented by threads
@Volatile RubyThread.Status status,
List<Lock> ownedLocks,
@Nullable FiberManager fiberManager,
Original file line number Diff line number Diff line change
@@ -83,10 +83,13 @@ private void poll(Node currentNode, boolean fromBlockingCall) {
@TruffleBoundary
private void assumptionInvalidated(Node currentNode, boolean fromBlockingCall) {
final DynamicObject thread = context.getThreadManager().getCurrentThread();
final boolean interruptible = (Layouts.THREAD.getInterruptMode(thread) == InterruptMode.IMMEDIATE) ||
(fromBlockingCall && Layouts.THREAD.getInterruptMode(thread) == InterruptMode.ON_BLOCKING);
final InterruptMode interruptMode = Layouts.THREAD.getInterruptMode(thread);

final boolean interruptible = (interruptMode == InterruptMode.IMMEDIATE) ||
(fromBlockingCall && interruptMode == InterruptMode.ON_BLOCKING);

if (!interruptible) {
Thread.currentThread().interrupt(); // keep the interrupt flag
return; // interrupt me later
}