< prev index next >

src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FixedAccessNode.java

Print this page
rev 56282 : [mq]: graal
   1 /*
   2  * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 
  25 package org.graalvm.compiler.nodes.memory;
  26 
  27 import org.graalvm.compiler.core.common.type.Stamp;
  28 import org.graalvm.compiler.graph.IterableNodeType;
  29 import org.graalvm.compiler.graph.NodeClass;
  30 import org.graalvm.compiler.nodeinfo.InputType;
  31 import org.graalvm.compiler.nodeinfo.NodeInfo;
  32 import org.graalvm.compiler.nodes.DeoptimizingFixedWithNextNode;
  33 import org.graalvm.compiler.nodes.FrameState;
  34 import org.graalvm.compiler.nodes.extended.GuardingNode;
  35 import org.graalvm.compiler.nodes.memory.address.AddressNode;
  36 import jdk.internal.vm.compiler.word.LocationIdentity;
  37 
  38 /**
  39  * Accesses a value at an memory address specified by an {@linkplain #address address}. The access
  40  * does not include a null check on the object.
  41  */
  42 @NodeInfo
  43 public abstract class FixedAccessNode extends DeoptimizingFixedWithNextNode implements Access, IterableNodeType {
  44     public static final NodeClass<FixedAccessNode> TYPE = NodeClass.create(FixedAccessNode.class);
  45 
  46     @OptionalInput(InputType.Guard) protected GuardingNode guard;
  47 
  48     @Input(InputType.Association) AddressNode address;
  49     protected final LocationIdentity location;
  50 
  51     protected boolean nullCheck;
  52     protected BarrierType barrierType;
  53 
  54     @Override
  55     public AddressNode getAddress() {
  56         return address;
  57     }
  58 
  59     @Override
  60     public void setAddress(AddressNode address) {
  61         updateUsages(this.address, address);
  62         this.address = address;
  63     }


   1 /*
   2  * Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 
  25 package org.graalvm.compiler.nodes.memory;
  26 
  27 import org.graalvm.compiler.core.common.type.Stamp;

  28 import org.graalvm.compiler.graph.NodeClass;
  29 import org.graalvm.compiler.nodeinfo.InputType;
  30 import org.graalvm.compiler.nodeinfo.NodeInfo;
  31 import org.graalvm.compiler.nodes.DeoptimizingFixedWithNextNode;
  32 import org.graalvm.compiler.nodes.FrameState;
  33 import org.graalvm.compiler.nodes.extended.GuardingNode;
  34 import org.graalvm.compiler.nodes.memory.address.AddressNode;
  35 import jdk.internal.vm.compiler.word.LocationIdentity;
  36 
  37 /**
  38  * Accesses a value at an memory address specified by an {@linkplain #address address}. The access
  39  * does not include a null check on the object.
  40  */
  41 @NodeInfo
  42 public abstract class FixedAccessNode extends DeoptimizingFixedWithNextNode implements Access {
  43     public static final NodeClass<FixedAccessNode> TYPE = NodeClass.create(FixedAccessNode.class);
  44 
  45     @OptionalInput(InputType.Guard) protected GuardingNode guard;
  46 
  47     @Input(InputType.Association) AddressNode address;
  48     protected final LocationIdentity location;
  49 
  50     protected boolean nullCheck;
  51     protected BarrierType barrierType;
  52 
  53     @Override
  54     public AddressNode getAddress() {
  55         return address;
  56     }
  57 
  58     @Override
  59     public void setAddress(AddressNode address) {
  60         updateUsages(this.address, address);
  61         this.address = address;
  62     }


< prev index next >