Search in sources :

Example 16 with LIRGeneratorTool

use of org.graalvm.compiler.lir.gen.LIRGeneratorTool in project graal by oracle.

the class WriteHeapBaseNode method generate.

@Override
public void generate(NodeLIRBuilderTool gen) {
    LIRGeneratorTool tool = gen.getLIRGeneratorTool();
    tool.emitMove(((SubstrateRegisterConfig) tool.getResult().getRegisterConfig()).getHeapBaseRegister().asValue(tool.getLIRKind(FrameAccess.getWordStamp())), gen.operand(value));
}
Also used : SubstrateRegisterConfig(com.oracle.svm.core.graal.meta.SubstrateRegisterConfig) LIRGeneratorTool(org.graalvm.compiler.lir.gen.LIRGeneratorTool)

Example 17 with LIRGeneratorTool

use of org.graalvm.compiler.lir.gen.LIRGeneratorTool in project graal by oracle.

the class ReadRegisterFixedNode method generate.

@Override
public void generate(NodeLIRBuilderTool gen) {
    LIRGeneratorTool tool = gen.getLIRGeneratorTool();
    SubstrateRegisterConfig registerConfig = (SubstrateRegisterConfig) tool.getRegisterConfig();
    LIRKind lirKind = tool.getLIRKind(FrameAccess.getWordStamp());
    RegisterValue value = registerSupplier.apply(registerConfig).asValue(lirKind);
    gen.setResult(this, tool.emitMove(value));
}
Also used : RegisterValue(jdk.vm.ci.code.RegisterValue) LIRKind(org.graalvm.compiler.core.common.LIRKind) SubstrateRegisterConfig(com.oracle.svm.core.graal.meta.SubstrateRegisterConfig) LIRGeneratorTool(org.graalvm.compiler.lir.gen.LIRGeneratorTool)

Example 18 with LIRGeneratorTool

use of org.graalvm.compiler.lir.gen.LIRGeneratorTool in project graal by oracle.

the class ValueCompareAndSwapNode method generate.

@Override
public void generate(NodeLIRBuilderTool gen) {
    assert getNewValue().stamp(NodeView.DEFAULT).isCompatible(getExpectedValue().stamp(NodeView.DEFAULT));
    LIRGeneratorTool tool = gen.getLIRGeneratorTool();
    assert !this.canDeoptimize();
    gen.setResult(this, tool.emitValueCompareAndSwap(gen.operand(getAddress()), gen.operand(getExpectedValue()), gen.operand(getNewValue())));
}
Also used : LIRGeneratorTool(org.graalvm.compiler.lir.gen.LIRGeneratorTool)

Aggregations

LIRGeneratorTool (org.graalvm.compiler.lir.gen.LIRGeneratorTool)18 Value (jdk.vm.ci.meta.Value)5 LIRKind (org.graalvm.compiler.core.common.LIRKind)5 SubstrateRegisterConfig (com.oracle.svm.core.graal.meta.SubstrateRegisterConfig)4 RegisterValue (jdk.vm.ci.code.RegisterValue)4 AllocatableValue (jdk.vm.ci.meta.AllocatableValue)3 SubstrateLIRGenerator (com.oracle.svm.core.graal.code.SubstrateLIRGenerator)1 BitSet (java.util.BitSet)1 LIRGenerationContext (org.graalvm.compiler.core.LIRGenerationPhase.LIRGenerationContext)1 AbstractBlockBase (org.graalvm.compiler.core.common.cfg.AbstractBlockBase)1 AbstractObjectStamp (org.graalvm.compiler.core.common.type.AbstractObjectStamp)1 DebugCloseable (org.graalvm.compiler.debug.DebugCloseable)1 DebugContext (org.graalvm.compiler.debug.DebugContext)1 LIR (org.graalvm.compiler.lir.LIR)1 LIRInstruction (org.graalvm.compiler.lir.LIRInstruction)1 VirtualStackSlot (org.graalvm.compiler.lir.VirtualStackSlot)1 AArch64AddressValue (org.graalvm.compiler.lir.aarch64.AArch64AddressValue)1 AMD64AddressValue (org.graalvm.compiler.lir.amd64.AMD64AddressValue)1 FrameMapBuilder (org.graalvm.compiler.lir.framemap.FrameMapBuilder)1 LIRGenerationResult (org.graalvm.compiler.lir.gen.LIRGenerationResult)1