Mercurial > hg > graal-jvmci-8
comparison agent/src/share/classes/sun/jvm/hotspot/tools/jcore/ByteCodeRewriter.java @ 20804:7848fc12602b
Merge with jdk8u40-b25
author | Gilles Duboscq <gilles.m.duboscq@oracle.com> |
---|---|
date | Tue, 07 Apr 2015 14:58:49 +0200 |
parents | 4ca6dc0799b6 64156d22e49d |
children |
comparison
equal
deleted
inserted
replaced
20184:84105dcdb05b | 20804:7848fc12602b |
---|---|
96 else | 96 else |
97 cpCacheIndex = method.getBytecodeIntArg(bci); | 97 cpCacheIndex = method.getBytecodeIntArg(bci); |
98 break; | 98 break; |
99 default: throw new IllegalArgumentException(); | 99 default: throw new IllegalArgumentException(); |
100 } | 100 } |
101 | |
101 if (cpCache == null) { | 102 if (cpCache == null) { |
102 return (short) cpCacheIndex; | 103 return (short) cpCacheIndex; |
103 } else if (fmt.indexOf("JJJJ") >= 0) { | 104 } else if (fmt.indexOf("JJJJ") >= 0) { |
104 // change byte-ordering and go via secondary cache entry | 105 // Invokedynamic require special handling |
105 throw new InternalError("unimplemented"); | 106 cpCacheIndex = ~cpCacheIndex; |
107 cpCacheIndex = bytes.swapInt(cpCacheIndex); | |
108 return (short) cpCache.getEntryAt(cpCacheIndex).getConstantPoolIndex(); | |
106 } else if (fmt.indexOf("JJ") >= 0) { | 109 } else if (fmt.indexOf("JJ") >= 0) { |
107 // change byte-ordering and go via cache | 110 // change byte-ordering and go via cache |
108 return (short) cpCache.getEntryAt((int) (0xFFFF & bytes.swapShort((short)cpCacheIndex))).getConstantPoolIndex(); | 111 return (short) cpCache.getEntryAt((int) (0xFFFF & bytes.swapShort((short)cpCacheIndex))).getConstantPoolIndex(); |
109 } else if (fmt.indexOf("j") >= 0) { | 112 } else if (fmt.indexOf("j") >= 0) { |
110 // go via cache | 113 // go via cache |