File tree Expand file tree Collapse file tree 4 files changed +12
-0
lines changed
compiler/src/jdk.graal.compiler/src/jdk/graal/compiler Expand file tree Collapse file tree 4 files changed +12
-0
lines changed Original file line number Diff line number Diff line change 64
64
import jdk .vm .ci .meta .MetaAccessProvider ;
65
65
import jdk .vm .ci .meta .ResolvedJavaMethod ;
66
66
import jdk .vm .ci .meta .ResolvedJavaType ;
67
+ import org .graalvm .nativeimage .Platform ;
68
+ import org .graalvm .nativeimage .Platforms ;
67
69
68
70
/**
69
71
* Filters certain method substitutions based on whether there is underlying hardware support for
@@ -274,6 +276,7 @@ public <T> T getInjectedArgument(Class<T> capability) {
274
276
return super .getInjectedArgument (capability );
275
277
}
276
278
279
+ @ Platforms (Platform .HOSTED_ONLY .class )
277
280
public ResolvedJavaMethod findSnippetMethod (ResolvedJavaMethod thisMethod ) {
278
281
if (snippetEncoder == null ) {
279
282
throw new GraalError ("findSnippetMethod called before initialization of Replacements" );
Original file line number Diff line number Diff line change 59
59
import jdk .vm .ci .hotspot .HotSpotJVMCIBackendFactory ;
60
60
import jdk .vm .ci .hotspot .HotSpotJVMCIRuntime ;
61
61
import jdk .vm .ci .services .JVMCIServiceLocator ;
62
+ import org .graalvm .nativeimage .Platform ;
63
+ import org .graalvm .nativeimage .Platforms ;
62
64
63
65
/**
64
66
* This class is used at image build-time when a libgraal image gets built. Its static methods are
65
67
* called from {@code com.oracle.svm.graal.hotspot.libgraal.LibGraalFeature} before static analysis.
66
68
* These methods ensure the static field state of Graal and JVMCI classes loaded by the
67
69
* LibGraalClassLoader is set up correctly for getting built into libgraal.
68
70
*/
71
+ @ Platforms (Platform .HOSTED_ONLY .class )
69
72
public class BuildTime {
70
73
71
74
private static final String VALID_LOADER_NAME = "LibGraalClassLoader" ;
Original file line number Diff line number Diff line change 27
27
import com .oracle .truffle .compiler .hotspot .libgraal .TruffleFromLibGraal .Id ;
28
28
import jdk .graal .compiler .truffle .host .TruffleHostEnvironment ;
29
29
import org .graalvm .nativeimage .ImageInfo ;
30
+ import org .graalvm .nativeimage .Platform ;
31
+ import org .graalvm .nativeimage .Platforms ;
30
32
31
33
import java .lang .invoke .MethodHandle ;
32
34
import java .lang .invoke .MethodHandles ;
45
47
/**
46
48
* Class used to initialize the Truffle extensions to the Graal compiler in the image build time.
47
49
*/
50
+ @ Platforms (Platform .HOSTED_ONLY .class )
48
51
public class BuildTime {
49
52
50
53
private static Lookup hostLookup ;
Original file line number Diff line number Diff line change 44
44
import jdk .vm .ci .runtime .JVMCI ;
45
45
import jdk .vm .ci .services .Services ;
46
46
import org .graalvm .nativeimage .ImageInfo ;
47
+ import org .graalvm .nativeimage .Platform ;
48
+ import org .graalvm .nativeimage .Platforms ;
47
49
48
50
/**
49
51
* Interface to functionality that abstracts over which JDK version Graal is running on.
@@ -75,6 +77,7 @@ public static boolean isInLibgraal() {
75
77
*/
76
78
private static Map <Class <?>, List <?>> libgraalServices ;
77
79
80
+ @ Platforms (Platform .HOSTED_ONLY .class )
78
81
@ ExcludeFromJacocoGeneratedReport ("only called when building libgraal" )
79
82
public static void setLibgraalServices (Map <Class <?>, List <?>> services ) {
80
83
GraalError .guarantee (libgraalServices == null , "Libgraal services must be set exactly once" );
You can’t perform that action at this time.
0 commit comments