equal
deleted
inserted
replaced
1672 |
1672 |
1673 *new_method_p = methodHandle(); // default is no new method |
1673 *new_method_p = methodHandle(); // default is no new method |
1674 |
1674 |
1675 // We cache a pointer to the bytecodes here in code_base. If GC |
1675 // We cache a pointer to the bytecodes here in code_base. If GC |
1676 // moves the Method*, then the bytecodes will also move which |
1676 // moves the Method*, then the bytecodes will also move which |
1677 // will likely cause a crash. We create a No_Safepoint_Verifier |
1677 // will likely cause a crash. We create a NoSafepointVerifier |
1678 // object to detect whether we pass a possible safepoint in this |
1678 // object to detect whether we pass a possible safepoint in this |
1679 // code block. |
1679 // code block. |
1680 No_Safepoint_Verifier nsv; |
1680 NoSafepointVerifier nsv; |
1681 |
1681 |
1682 // Bytecodes and their length |
1682 // Bytecodes and their length |
1683 address code_base = method->code_base(); |
1683 address code_base = method->code_base(); |
1684 int code_length = method->code_size(); |
1684 int code_length = method->code_size(); |
1685 |
1685 |
1733 Bytes::put_Java_u2(bcp, new_index); |
1733 Bytes::put_Java_u2(bcp, new_index); |
1734 |
1734 |
1735 Relocator rc(method, NULL /* no RelocatorListener needed */); |
1735 Relocator rc(method, NULL /* no RelocatorListener needed */); |
1736 methodHandle m; |
1736 methodHandle m; |
1737 { |
1737 { |
1738 Pause_No_Safepoint_Verifier pnsv(&nsv); |
1738 PauseNoSafepointVerifier pnsv(&nsv); |
1739 |
1739 |
1740 // ldc is 2 bytes and ldc_w is 3 bytes |
1740 // ldc is 2 bytes and ldc_w is 3 bytes |
1741 m = rc.insert_space_at(bci, 3, inst_buffer, CHECK); |
1741 m = rc.insert_space_at(bci, 3, inst_buffer, CHECK); |
1742 } |
1742 } |
1743 |
1743 |