Search in sources :

Example 11 with VMThreadLocalInfo

use of com.oracle.svm.core.threadlocal.VMThreadLocalInfo in project graal by oracle.

the class VMThreadSTFeature method handleCompareAndSet.

private boolean handleCompareAndSet(GraphBuilderContext b, ResolvedJavaMethod targetMethod, Receiver receiver, ValueNode expect, ValueNode update) {
    VMThreadLocalInfo threadLocalInfo = threadLocalCollector.findInfo(b, receiver.get());
    VMThreadLocalSTHolderNode holder = b.add(new VMThreadLocalSTHolderNode(threadLocalInfo));
    b.addPush(targetMethod.getSignature().getReturnKind(), new CompareAndSetVMThreadLocalNode(threadLocalInfo, holder, expect, update, BarrierType.PRECISE));
    return true;
}
Also used : VMThreadLocalSTHolderNode(com.oracle.svm.core.graal.thread.VMThreadLocalSTHolderNode) CompareAndSetVMThreadLocalNode(com.oracle.svm.core.graal.thread.CompareAndSetVMThreadLocalNode) VMThreadLocalInfo(com.oracle.svm.core.threadlocal.VMThreadLocalInfo)

Example 12 with VMThreadLocalInfo

use of com.oracle.svm.core.threadlocal.VMThreadLocalInfo in project graal by oracle.

the class VMThreadSTFeature method handleGet.

private boolean handleGet(GraphBuilderContext b, ResolvedJavaMethod targetMethod, Receiver receiver) {
    VMThreadLocalInfo info = threadLocalCollector.findInfo(b, receiver.get());
    VMThreadLocalSTHolderNode holder = b.add(new VMThreadLocalSTHolderNode(info));
    b.addPush(targetMethod.getSignature().getReturnKind(), new LoadVMThreadLocalNode(b.getMetaAccess(), info, holder, BarrierType.PRECISE));
    return true;
}
Also used : VMThreadLocalSTHolderNode(com.oracle.svm.core.graal.thread.VMThreadLocalSTHolderNode) VMThreadLocalInfo(com.oracle.svm.core.threadlocal.VMThreadLocalInfo) LoadVMThreadLocalNode(com.oracle.svm.core.graal.thread.LoadVMThreadLocalNode)

Aggregations

VMThreadLocalInfo (com.oracle.svm.core.threadlocal.VMThreadLocalInfo)12 VMThreadLocalSTHolderNode (com.oracle.svm.core.graal.thread.VMThreadLocalSTHolderNode)4 AddressOfVMThreadLocalNode (com.oracle.svm.core.graal.thread.AddressOfVMThreadLocalNode)2 CompareAndSetVMThreadLocalNode (com.oracle.svm.core.graal.thread.CompareAndSetVMThreadLocalNode)2 LoadVMThreadLocalNode (com.oracle.svm.core.graal.thread.LoadVMThreadLocalNode)2 StoreVMThreadLocalNode (com.oracle.svm.core.graal.thread.StoreVMThreadLocalNode)2 FastThreadLocal (com.oracle.svm.core.threadlocal.FastThreadLocal)2 MembarNode (org.graalvm.compiler.nodes.extended.MembarNode)2 ObjectLayout (com.oracle.svm.core.config.ObjectLayout)1 ReferenceMapEncoder (com.oracle.svm.core.heap.ReferenceMapEncoder)1 SubstrateReferenceMap (com.oracle.svm.core.heap.SubstrateReferenceMap)1 SharedField (com.oracle.svm.core.meta.SharedField)1 VMThreadLocalSTSupport (com.oracle.svm.core.threadlocal.VMThreadLocalSTSupport)1 CompilationAccessImpl (com.oracle.svm.hosted.FeatureImpl.CompilationAccessImpl)1 ArrayList (java.util.ArrayList)1 ResolvedJavaField (jdk.vm.ci.meta.ResolvedJavaField)1