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: ef8d7724397b
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: ca2eb28a547f
Choose a head ref
  • 4 commits
  • 8 files changed
  • 1 contributor

Commits on Aug 24, 2015

  1. [Truffle] Don't use GraphPE when debugging benchmarks.

    Error output isn't quite as good as the old FastPE.
    chrisseaton committed Aug 24, 2015
    Copy the full SHA
    444ead5 View commit details
  2. Copy the full SHA
    8d06150 View commit details
  3. Merge branch 'master' into truffle-head

    Conflicts:
    	tool/jt.rb
    chrisseaton committed Aug 24, 2015
    Copy the full SHA
    85f164d View commit details
  4. Copy the full SHA
    ca2eb28 View commit details
2 changes: 1 addition & 1 deletion tool/jt.rb
Original file line number Diff line number Diff line change
@@ -402,7 +402,7 @@ def bench(command, *args)
else
compilation_exceptions_behaviour = ",+TruffleCompilationExceptionsAreFatal"
end
env_vars = env_vars.merge({'JRUBY_OPTS' => "-J-Djvmci.options=+TraceTruffleCompilation,+DumpOnError#{compilation_exceptions_behaviour}"})
env_vars = env_vars.merge({'JRUBY_OPTS' => "-J-Djvmci.options=+TraceTruffleCompilation,+DumpOnError,-GraphPE#{compilation_exceptions_behaviour}"})
bench_args += ['score', 'jruby-9000-dev-truffle-graal', '--show-commands', '--show-samples']
raise 'specify a single benchmark for run - eg classic-fannkuch-redux' if args.size != 1
when 'reference'
2 changes: 1 addition & 1 deletion truffle/pom.rb
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@
repository( :url => 'http://lafo.ssw.uni-linz.ac.at/nexus/content/repositories/snapshots/',
:id => 'truffle' )

truffle_version = '0556c0056d7170bd00bba293082ca4ed4a511f51-SNAPSHOT'
truffle_version = '7646278cca8aafe582dff83c366f409b713089fc-SNAPSHOT'
jar 'com.oracle.truffle:truffle-api:' + truffle_version
jar 'com.oracle.truffle:truffle-dsl-processor:' + truffle_version, :scope => 'provided'
jar 'com.oracle.truffle:truffle-tck:' + truffle_version, :scope => 'test'
6 changes: 3 additions & 3 deletions truffle/pom.xml
Original file line number Diff line number Diff line change
@@ -31,18 +31,18 @@ DO NOT MODIFIY - GENERATED CODE
<dependency>
<groupId>com.oracle.truffle</groupId>
<artifactId>truffle-api</artifactId>
<version>0556c0056d7170bd00bba293082ca4ed4a511f51-SNAPSHOT</version>
<version>7646278cca8aafe582dff83c366f409b713089fc-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>com.oracle.truffle</groupId>
<artifactId>truffle-dsl-processor</artifactId>
<version>0556c0056d7170bd00bba293082ca4ed4a511f51-SNAPSHOT</version>
<version>7646278cca8aafe582dff83c366f409b713089fc-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.oracle.truffle</groupId>
<artifactId>truffle-tck</artifactId>
<version>0556c0056d7170bd00bba293082ca4ed4a511f51-SNAPSHOT</version>
<version>7646278cca8aafe582dff83c366f409b713089fc-SNAPSHOT</version>
<scope>test</scope>
</dependency>
<dependency>
Original file line number Diff line number Diff line change
@@ -1147,7 +1147,7 @@ public DynamicObject lambda(NotProvided block) {
@Specialization(guards = "isRubyProc(block)")
public DynamicObject lambda(DynamicObject block) {
return ProcNodes.createRubyProc(
getContext().getCoreLibrary().getProcClass(),
getContext().getCoreLibrary().getProcFactory(),
ProcNodes.Type.LAMBDA,
Layouts.PROC.getSharedMethodInfo(block),
Layouts.PROC.getCallTargetForLambdas(block),
Original file line number Diff line number Diff line change
@@ -244,7 +244,7 @@ public DynamicObject toProcUncached(DynamicObject methodObject) {
final InternalMethod method = Layouts.METHOD.getMethod(methodObject);

return ProcNodes.createRubyProc(
getContext().getCoreLibrary().getProcClass(),
getContext().getCoreLibrary().getProcFactory(),
ProcNodes.Type.LAMBDA,
method.getSharedMethodInfo(),
callTarget,
Original file line number Diff line number Diff line change
@@ -28,6 +28,8 @@
import org.jruby.truffle.nodes.RubyGuards;
import org.jruby.truffle.nodes.dispatch.CallDispatchHeadNode;
import org.jruby.truffle.nodes.dispatch.DispatchHeadNodeFactory;
import org.jruby.truffle.nodes.objects.AllocateObjectNode;
import org.jruby.truffle.nodes.objects.AllocateObjectNodeGen;
import org.jruby.truffle.nodes.yield.YieldDispatchHeadNode;
import org.jruby.truffle.runtime.NotProvided;
import org.jruby.truffle.runtime.RubyArguments;
@@ -93,10 +95,12 @@ public DynamicObject allocate(DynamicObject rubyClass) {
public abstract static class ProcNewNode extends CoreMethodArrayArgumentsNode {

@Child private CallDispatchHeadNode initializeNode;
@Child private AllocateObjectNode allocateObjectNode;

public ProcNewNode(RubyContext context, SourceSection sourceSection) {
super(context, sourceSection);
initializeNode = DispatchHeadNodeFactory.createMethodCallOnSelf(context);
allocateObjectNode = AllocateObjectNodeGen.create(context, sourceSection, null, null);
}

public abstract DynamicObject executeProcNew(VirtualFrame frame, DynamicObject procClass, Object[] args, Object block);
@@ -122,7 +126,7 @@ public DynamicObject procNormal(DynamicObject procClass, Object[] args, DynamicO
@Specialization(guards = "procClass != metaClass(block)")
public DynamicObject procSpecial(VirtualFrame frame, DynamicObject procClass, Object[] args, DynamicObject block) {
// Instantiate a new instance of procClass as classes do not correspond
DynamicObject proc = ProcNodes.createRubyProc(
DynamicObject proc = allocateObjectNode.allocate(
procClass,
Layouts.PROC.getType(block),
Layouts.PROC.getSharedMethodInfo(block),
@@ -145,13 +149,16 @@ protected DynamicObject metaClass(DynamicObject object) {
@CoreMethod(names = { "dup", "clone" })
public abstract static class DupNode extends UnaryCoreMethodNode {

@Child private AllocateObjectNode allocateObjectNode;

public DupNode(RubyContext context, SourceSection sourceSection) {
super(context, sourceSection);
allocateObjectNode = AllocateObjectNodeGen.create(context, sourceSection, null, null);
}

@Specialization
public DynamicObject dup(DynamicObject proc) {
DynamicObject copy = ProcNodes.createRubyProc(
DynamicObject copy = allocateObjectNode.allocate(
Layouts.BASIC_OBJECT.getLogicalClass(proc),
Layouts.PROC.getType(proc),
Layouts.PROC.getSharedMethodInfo(proc),
Original file line number Diff line number Diff line change
@@ -149,7 +149,7 @@ protected DynamicObject createProc(DynamicObject symbol) {
final CallTarget callTarget = Truffle.getRuntime().createCallTarget(rootNode);

return ProcNodes.createRubyProc(
getContext().getCoreLibrary().getProcClass(),
getContext().getCoreLibrary().getProcFactory(),
ProcNodes.Type.PROC,
sharedMethodInfo,
callTarget, callTarget, null,
Original file line number Diff line number Diff line change
@@ -2256,7 +2256,7 @@ public Object max(VirtualFrame frame, DynamicObject array) {
final VirtualFrame maximumClosureFrame = Truffle.getRuntime().createVirtualFrame(RubyArguments.pack(null, null, array, null, new Object[] {}), maxBlock.getFrameDescriptor());
maximumClosureFrame.setObject(maxBlock.getFrameSlot(), maximum);

final DynamicObject block = ProcNodes.createRubyProc(getContext().getCoreLibrary().getProcClass(), ProcNodes.Type.PROC,
final DynamicObject block = ProcNodes.createRubyProc(getContext().getCoreLibrary().getProcFactory(), ProcNodes.Type.PROC,
maxBlock.getSharedMethodInfo(), maxBlock.getCallTarget(), maxBlock.getCallTarget(),
maximumClosureFrame.materialize(), null, array, null);

@@ -2358,7 +2358,7 @@ public Object min(VirtualFrame frame, DynamicObject array) {
final VirtualFrame minimumClosureFrame = Truffle.getRuntime().createVirtualFrame(RubyArguments.pack(null, null, array, null, new Object[] {}), minBlock.getFrameDescriptor());
minimumClosureFrame.setObject(minBlock.getFrameSlot(), minimum);

final DynamicObject block = ProcNodes.createRubyProc(getContext().getCoreLibrary().getProcClass(), ProcNodes.Type.PROC,
final DynamicObject block = ProcNodes.createRubyProc(getContext().getCoreLibrary().getProcFactory(), ProcNodes.Type.PROC,
minBlock.getSharedMethodInfo(), minBlock.getCallTarget(), minBlock.getCallTarget(),
minimumClosureFrame.materialize(), null, array, null);