Skip to content

Commit 6ff51e1

Browse files
committed
Remove unused loop node factory service provider lookup.
1 parent 69b1ebb commit 6ff51e1

File tree

5 files changed

+7
-61
lines changed

5 files changed

+7
-61
lines changed

substratevm/src/com.oracle.svm.truffle/src/com/oracle/svm/truffle/api/SubstrateTruffleRuntime.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,6 @@ public final class SubstrateTruffleRuntime extends OptimizedTruffleRuntime {
128128
@Platforms(Platform.HOSTED_ONLY.class)
129129
public SubstrateTruffleRuntime() {
130130
super(new SubstrateTruffleCompilationSupport(), List.of());
131-
/* Ensure the factory class gets initialized. */
132-
super.getLoopNodeFactory();
133131
}
134132

135133
@Override

truffle/mx.truffle/suite.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1731,7 +1731,6 @@
17311731
],
17321732
"uses" : [
17331733
"com.oracle.truffle.api.impl.TruffleLocator",
1734-
"com.oracle.truffle.runtime.LoopNodeFactory",
17351734
"com.oracle.truffle.runtime.TruffleTypes",
17361735
"com.oracle.truffle.runtime.EngineCacheSupport",
17371736
"com.oracle.truffle.runtime.jfr.EventFactory.Provider",

truffle/src/com.oracle.truffle.runtime/src/META-INF/services/com.oracle.truffle.runtime.LoopNodeFactory

Lines changed: 0 additions & 1 deletion
This file was deleted.

truffle/src/com.oracle.truffle.runtime/src/com/oracle/truffle/runtime/DefaultLoopNodeFactory.java

Lines changed: 0 additions & 53 deletions
This file was deleted.

truffle/src/com.oracle.truffle.runtime/src/com/oracle/truffle/runtime/OptimizedTruffleRuntime.java

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,6 @@ public static OptimizedTruffleRuntime getRuntime() {
193193
return (OptimizedTruffleRuntime) Truffle.getRuntime();
194194
}
195195

196-
private final LoopNodeFactory loopNodeFactory;
197196
private EngineCacheSupport engineCacheSupport;
198197
private final Iterable<Class<?>> extraLookupTypes;
199198
private UnmodifiableEconomicMap<String, Class<?>> lookupTypes;
@@ -209,7 +208,6 @@ public OptimizedTruffleRuntime(TruffleCompilationSupport compilationSupport, Ite
209208
this.compilationSupport = compilationSupport;
210209
this.extraLookupTypes = extraLookupTypes;
211210
List<OptionDescriptors> options = new ArrayList<>();
212-
this.loopNodeFactory = loadGraalRuntimeServiceProvider(LoopNodeFactory.class, options, true);
213211
EngineCacheSupport support = loadEngineCacheSupport(options);
214212
this.engineCacheSupport = support == null ? new EngineCacheSupport.Disabled() : support;
215213
this.previousEngineCacheSupportOptions = engineCacheSupport.getEngineOptions();
@@ -640,11 +638,16 @@ public LoopNode createLoopNode(RepeatingNode repeatingNode) {
640638
if (!(repeatingNode instanceof Node)) {
641639
throw new IllegalArgumentException("Repeating node must be of type Node.");
642640
}
643-
return getLoopNodeFactory().create(repeatingNode);
641+
return OptimizedOSRLoopNode.create(repeatingNode);
644642
}
645643

644+
/**
645+
* @deprecated do not use just here for compatibility with older SubstrateTruffleRuntime.
646+
*/
647+
@SuppressWarnings("static-method")
648+
@Deprecated
646649
protected final LoopNodeFactory getLoopNodeFactory() {
647-
return loopNodeFactory;
650+
return null;
648651
}
649652

650653
public final EngineCacheSupport getEngineCacheSupport() {

0 commit comments

Comments
 (0)