MCPcopy Create free account
hub / github.com/GANGE666/xVMP / getDecodedCastOpcode

Function getDecodedCastOpcode

src/lib/Bitcode/Reader/BitcodeReader.cpp:953–970  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

951}
952
953static int getDecodedCastOpcode(unsigned Val) {
954 switch (Val) {
955 default: return -1;
956 case bitc::CAST_TRUNC : return Instruction::Trunc;
957 case bitc::CAST_ZEXT : return Instruction::ZExt;
958 case bitc::CAST_SEXT : return Instruction::SExt;
959 case bitc::CAST_FPTOUI : return Instruction::FPToUI;
960 case bitc::CAST_FPTOSI : return Instruction::FPToSI;
961 case bitc::CAST_UITOFP : return Instruction::UIToFP;
962 case bitc::CAST_SITOFP : return Instruction::SIToFP;
963 case bitc::CAST_FPTRUNC : return Instruction::FPTrunc;
964 case bitc::CAST_FPEXT : return Instruction::FPExt;
965 case bitc::CAST_PTRTOINT: return Instruction::PtrToInt;
966 case bitc::CAST_INTTOPTR: return Instruction::IntToPtr;
967 case bitc::CAST_BITCAST : return Instruction::BitCast;
968 case bitc::CAST_ADDRSPACECAST: return Instruction::AddrSpaceCast;
969 }
970}
971
972static int getDecodedUnaryOpcode(unsigned Val, Type *Ty) {
973 bool IsFP = Ty->isFPOrFPVectorTy();

Callers 2

parseConstantsMethod · 0.85
parseFunctionBodyMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected