Mercurial > hg > graal-jvmci-8
comparison jvmci/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterValue.java @ 23396:9ed5b586018b
Replace LIRKind with abstract base class (JDK-8156942).
author | Roland Schatz <roland.schatz@oracle.com> |
---|---|
date | Fri, 13 May 2016 14:33:19 +0200 |
parents | 1bbd4a7c274b |
children | a7b12c1ab514 |
comparison
equal
deleted
inserted
replaced
23395:19432ed40848 | 23396:9ed5b586018b |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | 4 * |
5 * This code is free software; you can redistribute it and/or modify it | 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 | 6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
22 */ | 22 */ |
23 package jdk.vm.ci.code; | 23 package jdk.vm.ci.code; |
24 | 24 |
25 import jdk.vm.ci.meta.AllocatableValue; | 25 import jdk.vm.ci.meta.AllocatableValue; |
26 import jdk.vm.ci.meta.JavaKind; | 26 import jdk.vm.ci.meta.JavaKind; |
27 import jdk.vm.ci.meta.LIRKind; | 27 import jdk.vm.ci.meta.ValueKind; |
28 | 28 |
29 /** | 29 /** |
30 * Denotes a register that stores a value of a fixed kind. There is exactly one (canonical) instance | 30 * Denotes a register that stores a value of a fixed kind. There is exactly one (canonical) instance |
31 * of {@link RegisterValue} for each ({@link Register}, {@link JavaKind}) pair. Use | 31 * of {@link RegisterValue} for each ({@link Register}, {@link JavaKind}) pair. Use |
32 * {@link Register#asValue(LIRKind)} to retrieve the canonical {@link RegisterValue} instance for a | 32 * {@link Register#asValue(ValueKind)} to retrieve the canonical {@link RegisterValue} instance for |
33 * given (register,kind) pair. | 33 * a given (register,kind) pair. |
34 */ | 34 */ |
35 public final class RegisterValue extends AllocatableValue { | 35 public final class RegisterValue extends AllocatableValue { |
36 | 36 |
37 private final Register reg; | 37 private final Register reg; |
38 | 38 |
39 /** | 39 /** |
40 * Should only be called from {@link Register#Register} to ensure canonicalization. | 40 * Should only be called from {@link Register#Register} to ensure canonicalization. |
41 */ | 41 */ |
42 protected RegisterValue(LIRKind kind, Register register) { | 42 protected RegisterValue(ValueKind<?> kind, Register register) { |
43 super(kind); | 43 super(kind); |
44 this.reg = register; | 44 this.reg = register; |
45 } | 45 } |
46 | 46 |
47 @Override | 47 @Override |