-
-
Notifications
You must be signed in to change notification settings - Fork 925
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- 9.4.12.0
- 9.4.11.0
- 9.4.10.0
- 9.4.9.0
- 9.4.8.0
- 9.4.7.0
- 9.4.6.0
- 9.4.5.0
- 9.4.4.0
- 9.4.3.0
- 9.4.2.0
- 9.4.1.0
- 9.4.0.0
- 9.3.15.0
- 9.3.14.0
- 9.3.13.0
- 9.3.12.0
- 9.3.11.0
- 9.3.10.0
- 9.3.9.0
- 9.3.8.0
- 9.3.7.0
- 9.3.6.0
- 9.3.5.0
- 9.3.4.0
- 9.3.3.0
- 9.3.2.0
- 9.3.1.0
- 9.3.0.0
- 9.2.21.0
- 9.2.20.1
- 9.2.20.0
- 9.2.19.0
- 9.2.18.0
- 9.2.17.0
- 9.2.16.0
- 9.2.15.0
- 9.2.14.0
- 9.2.13.0
- 9.2.12.0
- 9.2.11.1
- 9.2.11.0
- 9.2.10.0
- 9.2.9.0
- 9.2.8.0
- 9.2.7.0
- 9.2.6.0
- 9.2.5.0
- 9.2.4.1
- 9.2.4.0
- 9.2.3.0
- 9.2.2.0
- 9.2.1.0
- 9.2.0.0
- 9.1.17.0
- 9.1.16.0
- 9.1.15.0
- 9.1.14.0
- 9.1.13.0
- 9.1.12.0
- 9.1.11.0
- 9.1.10.0
- 9.1.9.0
- 9.1.8.0
- 9.1.7.0
- 9.1.6.0
- 9.1.5.0
- 9.1.4.0
- 9.1.3.0
- 9.1.2.0
- 9.1.1.0
- 9.1.0.0
Showing
129 changed files
with
1,938 additions
and
2,895 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
#!/usr/bin/env jruby | ||
|
||
# Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. | ||
# This code is released under a tri EPL/GPL/LGPL license. You can use it, | ||
# redistribute it and/or modify it under the terms of the: | ||
# | ||
# Eclipse Public License version 1.0 | ||
# GNU General Public License version 2 | ||
# GNU Lesser General Public License version 2.1 | ||
|
||
# A compiler for JRuby+Truffle C extensions | ||
|
||
require 'yaml' | ||
|
||
MX_DIR = ENV['MX_DIR'] | ||
|
||
unless MX_DIR | ||
abort 'You need to set MX_DIR to a checkout of the mx repository' | ||
end | ||
|
||
SULONG_DIR = ENV['SULONG_DIR'] | ||
|
||
unless SULONG_DIR | ||
abort 'You need to set SULONG_DIR to the location of a built checkout of the Sulong repository' | ||
end | ||
|
||
def mx(command, *args) | ||
command = "#{MX_DIR}/mx.py -p #{SULONG_DIR} --vm server #{command} #{args.join(' ')}" | ||
puts "$ #{command}" | ||
`#{command}` | ||
end | ||
|
||
CEXT_DIR = ARGV[0] | ||
|
||
unless CEXT_DIR | ||
abort 'You need to pass the directory of a C extension so I can build it' | ||
end | ||
|
||
CONFIG_FILE = File.join(CEXT_DIR, '.jruby-cext-build.yml') | ||
|
||
unless File.exist?(CONFIG_FILE) | ||
abort "There is no .jruby-cext-build.yml in this C extension at the moment - I don't know how to build it" | ||
end | ||
|
||
CONFIG = YAML.load_file(CONFIG_FILE) | ||
|
||
SRC = Dir[File.join(CEXT_DIR, CONFIG['src'])] | ||
OUT = File.join(CEXT_DIR, CONFIG['out']) | ||
|
||
LL = [] | ||
|
||
SRC.each do |src| | ||
ll = File.join(File.dirname(src), File.basename(src, '.*') + '.ll') | ||
mx 'su-clang', "-I#{SULONG_DIR}/include", '-Ilib/ruby/truffle/cext', '-S', '-emit-llvm', src, '-o', ll | ||
LL.push ll | ||
end | ||
|
||
mx 'su-link', '-o', OUT, *LL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
core/src/main/resources/META-INF/services/java.nio.file.spi.FileTypeDetector
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
org.jruby.util.RubyFiletypeDetector | ||
org.jruby.util.RubyFileTypeDetector |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 0 additions & 19 deletions
19
spec/truffle/specs/truffle/primitive/coverage_result_spec.rb
This file was deleted.
Oops, something went wrong.
19 changes: 0 additions & 19 deletions
19
spec/truffle/specs/truffle/primitive/coverage_start_spec.rb
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
fails:Truffle::Attachments.attach only runs the block once each time the line is executed | ||
fails:Truffle::Attachments.attach allows multiple blocks to be installed on the same line and runs both of them |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
src: ext/minimum/*.c | ||
out: lib/minimum/minimum.su |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env ruby | ||
|
||
require 'minimum' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#include <stdio.h> | ||
|
||
void Init_minimum() { | ||
printf("Hello!\n"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
require 'minimum/minimum' |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env bash | ||
|
||
ruby -X+T -J-G:+TruffleCompilationExceptionsAreFatal test/truffle/compiler/stf-optimises/stf-optimises.rb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Copyright (c) 2015, 2016 Oracle and/or its affiliates. All rights reserved. This | ||
# code is released under a tri EPL/GPL/LGPL license. You can use it, | ||
# redistribute it and/or modify it under the terms of the: | ||
# | ||
# Eclipse Public License version 1.0 | ||
# GNU General Public License version 2 | ||
# GNU Lesser General Public License version 2.1 | ||
|
||
def foo | ||
foo = 14 | ||
foo * 2 | ||
end | ||
|
||
set_trace_func proc { |event, file, line, id, binding, classname| | ||
if event == 'line' && file == __FILE__ && line == 11 | ||
binding.local_variable_set(:foo, 100) | ||
end | ||
} | ||
|
||
begin | ||
loop do | ||
x = foo | ||
raise 'value not correct' unless x == 200 | ||
Truffle::Primitive.assert_constant x | ||
Truffle::Primitive.assert_not_compiled | ||
end | ||
rescue RubyTruffleError => e | ||
if e.message.include? 'Truffle::Primitive.assert_not_compiled' | ||
puts 'STF optimising' | ||
exit 0 | ||
elsif e.message.include? 'Truffle::Primitive.assert_constant' | ||
puts 'STF not optimising' | ||
exit 1 | ||
else | ||
puts 'some other error' | ||
exit 1 | ||
end | ||
end | ||
|
||
exit 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env bash | ||
|
||
ruby -X+T -J-G:+TruffleCompilationExceptionsAreFatal test/truffle/compiler/tp-optimises/tp-optimises.rb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Copyright (c) 2015, 2016 Oracle and/or its affiliates. All rights reserved. This | ||
# code is released under a tri EPL/GPL/LGPL license. You can use it, | ||
# redistribute it and/or modify it under the terms of the: | ||
# | ||
# Eclipse Public License version 1.0 | ||
# GNU General Public License version 2 | ||
# GNU Lesser General Public License version 2.1 | ||
|
||
def foo | ||
foo = 14 | ||
foo * 2 | ||
end | ||
|
||
tp = TracePoint.new(:line) do |tp| | ||
tp.binding.local_variable_set(:foo, 100) | ||
end | ||
|
||
tp.enable | ||
|
||
begin | ||
loop do | ||
x = foo | ||
raise 'value not correct' unless x == 200 | ||
Truffle::Primitive.assert_constant x | ||
Truffle::Primitive.assert_not_compiled | ||
end | ||
rescue RubyTruffleError => e | ||
if e.message.include? 'Truffle::Primitive.assert_not_compiled' | ||
puts 'TP optimising' | ||
exit 0 | ||
elsif e.message.include? 'Truffle::Primitive.assert_constant' | ||
puts 'TP not optimising' | ||
exit 1 | ||
else | ||
puts 'some other error' | ||
exit 1 | ||
end | ||
end | ||
|
||
exit 1 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env bash | ||
|
||
ruby -X+T test/truffle/integration/coverage/test.rb |
Oops, something went wrong.