MCPcopy Create free account
hub / github.com/IntegralPilot/rustc_codegen_jvm / branch_targets

Function branch_targets

src/lower2/stackmaps.rs:1388–1442  ·  view source on GitHub ↗
(instructions: &[Instruction])

Source from the content-addressed store, hash-verified

1386 state.stack.push(FrameValue::Integer);
1387 }
1388 I::Laload => array_load(&mut state, FrameValue::Long, context, instruction_index)?,
1389 I::Faload => array_load(&mut state, FrameValue::Float, context, instruction_index)?,
1390 I::Daload => array_load(&mut state, FrameValue::Double, context, instruction_index)?,
1391 I::Aaload => {
1392 state.pop(context, instruction_index)?;
1393 let array = state.pop_reference(context, instruction_index)?;
1394 state.stack.push(array_component_value(&array));
1395 }
1396 I::Iastore
1397 | I::Lastore
1398 | I::Fastore
1399 | I::Dastore
1400 | I::Aastore
1401 | I::Bastore
1402 | I::Castore
1403 | I::Sastore => {
1404 state.pop(context, instruction_index)?;
1405 state.pop(context, instruction_index)?;
1406 state.pop_reference(context, instruction_index)?;
1407 }
1408
1409 I::Pop => {
1410 state.pop(context, instruction_index)?;
1411 }
1412 I::Pop2 => {
1413 let value = state.pop(context, instruction_index)?;
1414 if !value.is_category2() {
1415 state.pop(context, instruction_index)?;
1416 }
1417 }
1418 I::Dup => {
1419 let value = state.pop_category1(context, instruction_index)?;
1420 state.stack.push(value.clone());
1421 state.stack.push(value);
1422 }
1423 I::Swap => {
1424 let first = state.pop_category1(context, instruction_index)?;
1425 let second = state.pop_category1(context, instruction_index)?;
1426 state.stack.push(first);
1427 state.stack.push(second);
1428 }
1429 I::Dup_x1 => {
1430 let value1 = state.pop_category1(context, instruction_index)?;
1431 let value2 = state.pop_category1(context, instruction_index)?;
1432 state.stack.push(value1.clone());
1433 state.stack.push(value2);
1434 state.stack.push(value1);
1435 }
1436 I::Dup2 => {
1437 let value1 = state.pop(context, instruction_index)?;
1438 if value1.is_category2() {
1439 state.stack.push(value1.clone());
1440 state.stack.push(value1);
1441 } else {
1442 let value2 = state.pop_category1(context, instruction_index)?;
1443 state.stack.push(value2.clone());
1444 state.stack.push(value1.clone());
1445 state.stack.push(value2);

Callers 1

Calls 1

Tested by

no test coverage detected