Mercurial > hg > graal-jvmci-8
comparison src/cpu/x86/vm/graalCodeInstaller_x86.hpp @ 13520:fb7b39f07232
Embed compressed constants when possible and use more efficient patterns for encoding
author | Tom Rodriguez <tom.rodriguez@oracle.com> |
---|---|
date | Mon, 06 Jan 2014 17:19:18 -0800 |
parents | fa5180b3c18e |
children | d49f00604347 |
comparison
equal
deleted
inserted
replaced
13519:1ceb90be7bac | 13520:fb7b39f07232 |
---|---|
78 switch (typeChar) { | 78 switch (typeChar) { |
79 case 'z': | 79 case 'z': |
80 case 'b': | 80 case 'b': |
81 case 's': | 81 case 's': |
82 case 'c': | 82 case 'c': |
83 case 'i': | |
84 fatal("int-sized values not expected in DataPatch"); | 83 fatal("int-sized values not expected in DataPatch"); |
85 break; | 84 break; |
85 | |
86 case 'i': { | |
87 address operand = Assembler::locate_operand(pc, Assembler::narrow_oop_operand); | |
88 Handle obj = Constant::object(constant); | |
89 | |
90 jobject value = JNIHandles::make_local(obj()); | |
91 int oop_index = _oop_recorder->find_index(value); | |
92 _instructions->relocate(pc, oop_Relocation::spec(oop_index), Assembler::narrow_oop_operand); | |
93 TRACE_graal_3("relocating (narrow oop constant) at %p/%p", pc, operand); | |
94 break; | |
95 } | |
96 | |
86 case 'f': | 97 case 'f': |
87 case 'j': | 98 case 'j': |
88 case 'd': | 99 case 'd': |
89 case '*': { | 100 case '*': { |
90 if (inlined) { | 101 if (inlined) { |