96 __ bctr();
97
98 __ bind(L_skip_barrier);
99 }
100
101 void LIR_Assembler::osr_entry() {
102 // On-stack-replacement entry sequence:
103 //
104 // 1. Create a new compiled activation.
105 // 2. Initialize local variables in the compiled activation. The expression
106 // stack must be empty at the osr_bci; it is not initialized.
107 // 3. Jump to the continuation address in compiled code to resume execution.
108
109 // OSR entry point
110 offsets()->set_value(CodeOffsets::OSR_Entry, code_offset());
111 BlockBegin* osr_entry = compilation()->hir()->osr_entry();
112 ValueStack* entry_state = osr_entry->end()->state();
113 int number_of_locks = entry_state->locks_size();
114
115 // Create a frame for the compiled activation.
116 __ build_frame(initial_frame_size_in_bytes(), bang_size_in_bytes());
117
118 // OSR buffer is
119 //
120 // locals[nlocals-1..0]
121 // monitors[number_of_locks-1..0]
122 //
123 // Locals is a direct copy of the interpreter frame so in the osr buffer
124 // the first slot in the local array is the last local from the interpreter
125 // and the last slot is local[0] (receiver) from the interpreter.
126 //
127 // Similarly with locks. The first lock slot in the osr buffer is the nth lock
128 // from the interpreter frame, the nth lock slot in the osr buffer is 0th lock
129 // in the interpreter frame (the method lock if a sync method).
130
131 // Initialize monitors in the compiled activation.
132 // R3: pointer to osr buffer
133 //
134 // All other registers are dead at this point and the locals will be
135 // copied into place by code emitted in the IR.
136
|
96 __ bctr();
97
98 __ bind(L_skip_barrier);
99 }
100
101 void LIR_Assembler::osr_entry() {
102 // On-stack-replacement entry sequence:
103 //
104 // 1. Create a new compiled activation.
105 // 2. Initialize local variables in the compiled activation. The expression
106 // stack must be empty at the osr_bci; it is not initialized.
107 // 3. Jump to the continuation address in compiled code to resume execution.
108
109 // OSR entry point
110 offsets()->set_value(CodeOffsets::OSR_Entry, code_offset());
111 BlockBegin* osr_entry = compilation()->hir()->osr_entry();
112 ValueStack* entry_state = osr_entry->end()->state();
113 int number_of_locks = entry_state->locks_size();
114
115 // Create a frame for the compiled activation.
116 __ build_frame(initial_frame_size_in_bytes(), bang_size_in_bytes(), compilation()->max_monitors());
117
118 // OSR buffer is
119 //
120 // locals[nlocals-1..0]
121 // monitors[number_of_locks-1..0]
122 //
123 // Locals is a direct copy of the interpreter frame so in the osr buffer
124 // the first slot in the local array is the last local from the interpreter
125 // and the last slot is local[0] (receiver) from the interpreter.
126 //
127 // Similarly with locks. The first lock slot in the osr buffer is the nth lock
128 // from the interpreter frame, the nth lock slot in the osr buffer is 0th lock
129 // in the interpreter frame (the method lock if a sync method).
130
131 // Initialize monitors in the compiled activation.
132 // R3: pointer to osr buffer
133 //
134 // All other registers are dead at this point and the locals will be
135 // copied into place by code emitted in the IR.
136
|