Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Q
QueryR
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Julien Lopez
QueryR
Commits
f5014483
Commit
f5014483
authored
7 years ago
by
Stepan Sindelar
Browse files
Options
Downloads
Plain Diff
[GR-2798] Avoid memory leak in tests.
parents
eb61b6be
9db8d239
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
com.oracle.truffle.r.engine/src/com/oracle/truffle/r/engine/REngine.java
+12
-6
12 additions, 6 deletions
...fle.r.engine/src/com/oracle/truffle/r/engine/REngine.java
mx.fastr/suite.py
+1
-1
1 addition, 1 deletion
mx.fastr/suite.py
with
13 additions
and
7 deletions
com.oracle.truffle.r.engine/src/com/oracle/truffle/r/engine/REngine.java
+
12
−
6
View file @
f5014483
...
...
@@ -533,7 +533,7 @@ final class REngine implements Engine, Engine.Timings {
*/
@TruffleBoundary
private
RootCallTarget
doMakeCallTarget
(
RNode
body
,
String
description
,
boolean
printResult
,
boolean
topLevel
)
{
return
Truffle
.
getRuntime
().
createCallTarget
(
new
AnonymousRootNode
(
body
,
description
,
printResult
,
topLevel
));
return
Truffle
.
getRuntime
().
createCallTarget
(
new
AnonymousRootNode
(
this
,
body
,
description
,
printResult
,
topLevel
));
}
/**
...
...
@@ -544,7 +544,7 @@ final class REngine implements Engine, Engine.Timings {
* context of that frame. Note that passing only this one frame argument, strictly spoken,
* violates the frame layout as set forth in {@link RArguments}. This is for internal use only.
*/
private
final
class
AnonymousRootNode
extends
RootNode
implements
RootWithBody
{
private
static
final
class
AnonymousRootNode
extends
RootNode
implements
RootWithBody
{
private
final
ValueProfile
frameTypeProfile
=
ValueProfile
.
createClassProfile
();
private
final
ConditionProfile
isVirtualFrameProfile
=
ConditionProfile
.
createBinaryProfile
();
...
...
@@ -552,13 +552,15 @@ final class REngine implements Engine, Engine.Timings {
private
final
String
description
;
private
final
boolean
printResult
;
private
final
boolean
topLevel
;
private
final
boolean
suppressWarnings
;
@Child
private
RNode
body
;
@Child
private
GetVisibilityNode
visibility
=
GetVisibilityNode
.
create
();
@Child
private
SetVisibilityNode
setVisibility
=
SetVisibilityNode
.
create
();
protected
AnonymousRootNode
(
RNode
body
,
String
description
,
boolean
printResult
,
boolean
topLevel
)
{
super
(
context
.
getLanguage
());
protected
AnonymousRootNode
(
REngine
engine
,
RNode
body
,
String
description
,
boolean
printResult
,
boolean
topLevel
)
{
super
(
engine
.
context
.
getLanguage
());
this
.
suppressWarnings
=
engine
.
suppressWarnings
;
this
.
body
=
body
;
this
.
description
=
description
;
this
.
printResult
=
printResult
;
...
...
@@ -597,7 +599,7 @@ final class REngine implements Engine, Engine.Timings {
if
(
printResult
&&
result
!=
null
)
{
assert
topLevel
;
if
(
visibility
.
execute
(
vf
))
{
printResult
(
result
);
printResult
Impl
(
result
);
}
}
if
(
topLevel
)
{
...
...
@@ -665,8 +667,12 @@ final class REngine implements Engine, Engine.Timings {
}
@Override
@TruffleBoundary
public
void
printResult
(
Object
originalResult
)
{
printResultImpl
(
originalResult
);
}
@TruffleBoundary
static
void
printResultImpl
(
Object
originalResult
)
{
Object
result
=
evaluatePromise
(
originalResult
);
result
=
RRuntime
.
asAbstractVector
(
result
);
if
(
result
instanceof
RTypedValue
||
result
instanceof
TruffleObject
)
{
...
...
This diff is collapsed.
Click to expand it.
mx.fastr/suite.py
+
1
−
1
View file @
f5014483
...
...
@@ -29,7 +29,7 @@ suite = {
{
"
name
"
:
"
truffle
"
,
"
subdir
"
:
True
,
"
version
"
:
"
05b61f9fa9dceebec447f3ec3656c8cc5be215dd
"
,
"
version
"
:
"
b29a94a6738f96c33be981681b69216a1664eb8a
"
,
"
urls
"
:
[
{
"
url
"
:
"
https://github.com/graalvm/graal
"
,
"
kind
"
:
"
git
"
},
{
"
url
"
:
"
https://curio.ssw.jku.at/nexus/content/repositories/snapshots
"
,
"
kind
"
:
"
binary
"
},
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment