| 1417 | } |
| 1418 | |
| 1419 | CeOperand CeBuilder::EmitConst(int64 val, int size) |
| 1420 | { |
| 1421 | BeType* type = mIntPtrType; |
| 1422 | switch (size) |
| 1423 | { |
| 1424 | case 1: |
| 1425 | type = mCeMachine->GetBeContext()->GetPrimitiveType(BeTypeCode_Int8); |
| 1426 | break; |
| 1427 | case 2: |
| 1428 | type = mCeMachine->GetBeContext()->GetPrimitiveType(BeTypeCode_Int16); |
| 1429 | break; |
| 1430 | case 4: |
| 1431 | type = mCeMachine->GetBeContext()->GetPrimitiveType(BeTypeCode_Int32); |
| 1432 | break; |
| 1433 | case 8: |
| 1434 | type = mCeMachine->GetBeContext()->GetPrimitiveType(BeTypeCode_Int64); |
| 1435 | break; |
| 1436 | default: |
| 1437 | Fail("Bad const size"); |
| 1438 | } |
| 1439 | |
| 1440 | auto result = FrameAlloc(type); |
| 1441 | |
| 1442 | EmitSizedOp(CeOp_Const_8, type->mSize); |
| 1443 | EmitFrameOffset(result); |
| 1444 | Emit(&val, size); |
| 1445 | return result; |
| 1446 | } |
| 1447 | |
| 1448 | int CeBuilder::GetCallTableIdx(BeFunction* beFunction, CeOperand* outOperand) |
| 1449 | { |
nothing calls this directly
no test coverage detected