File tree Expand file tree Collapse file tree 3 files changed +5
-10
lines changed
src/main/java/org/truffleruby Expand file tree Collapse file tree 3 files changed +5
-10
lines changed Original file line number Diff line number Diff line change 7
7
{
8
8
"name" : "regex" ,
9
9
"subdir" : True ,
10
- "version" : "c7604b7fd48cc8c3509cf215cd5e268748a81d85 " ,
10
+ "version" : "86651e3bf6af2662ada38eccdf1f5ebe632d30db " ,
11
11
"urls" : [
12
12
{"url" : "https://github.com/oracle/graal.git" , "kind" : "git" },
13
13
{"url" : "https://curio.ssw.jku.at/nexus/content/repositories/snapshots" , "kind" : "binary" },
16
16
{
17
17
"name" : "sulong" ,
18
18
"subdir" : True ,
19
- "version" : "c7604b7fd48cc8c3509cf215cd5e268748a81d85 " ,
19
+ "version" : "86651e3bf6af2662ada38eccdf1f5ebe632d30db " ,
20
20
"urls" : [
21
21
{"url" : "https://github.com/oracle/graal.git" , "kind" : "git" },
22
22
{"url" : "https://curio.ssw.jku.at/nexus/content/repositories/snapshots" , "kind" : "binary" },
Original file line number Diff line number Diff line change 16
16
import com .oracle .truffle .api .nodes .LoopNode ;
17
17
import com .oracle .truffle .api .nodes .Node ;
18
18
import com .oracle .truffle .api .nodes .RepeatingNode ;
19
- import com .oracle .truffle .api .profiles .ConditionProfile ;
20
19
21
20
public class StarNode extends FormatNode {
22
21
@@ -36,15 +35,13 @@ private class StarRepeatingNode extends Node implements RepeatingNode {
36
35
37
36
@ Child private FormatNode child ;
38
37
39
- private final ConditionProfile conditionProfile = ConditionProfile .create ();
40
-
41
38
public StarRepeatingNode (FormatNode child ) {
42
39
this .child = child ;
43
40
}
44
41
45
42
@ Override
46
43
public boolean executeRepeating (VirtualFrame frame ) {
47
- if (conditionProfile . profile ( getSourcePosition (frame ) >= getSourceLength (frame ) )) {
44
+ if (getSourcePosition (frame ) >= getSourceLength (frame )) {
48
45
return false ;
49
46
}
50
47
Original file line number Diff line number Diff line change 22
22
import com .oracle .truffle .api .nodes .LoopNode ;
23
23
import com .oracle .truffle .api .nodes .RepeatingNode ;
24
24
import com .oracle .truffle .api .profiles .BranchProfile ;
25
- import com .oracle .truffle .api .profiles .LoopConditionProfile ;
26
25
27
26
public final class WhileNode extends RubyContextSourceNode {
28
27
@@ -43,7 +42,6 @@ private abstract static class WhileRepeatingBaseNode extends RubyBaseNode implem
43
42
@ Child protected BooleanCastNode condition ;
44
43
@ Child protected RubyNode body ;
45
44
46
- protected final LoopConditionProfile conditionProfile = LoopConditionProfile .createCountingProfile ();
47
45
protected final BranchProfile redoUsed = BranchProfile .create ();
48
46
protected final BranchProfile nextUsed = BranchProfile .create ();
49
47
@@ -67,7 +65,7 @@ public WhileRepeatingNode(RubyNode condition, RubyNode body) {
67
65
68
66
@ Override
69
67
public boolean executeRepeating (VirtualFrame frame ) {
70
- if (!conditionProfile . profile ( condition .executeBoolean (frame ) )) {
68
+ if (!condition .executeBoolean (frame )) {
71
69
return false ;
72
70
}
73
71
@@ -106,7 +104,7 @@ public boolean executeRepeating(VirtualFrame frame) {
106
104
return true ;
107
105
}
108
106
109
- return conditionProfile . profile ( condition .executeBoolean (frame ) );
107
+ return condition .executeBoolean (frame );
110
108
}
111
109
112
110
}
You can’t perform that action at this time.
0 commit comments