MCPcopy Create free account
hub / github.com/AliveToolkit/alive2 / parse_exceptions

Function parse_exceptions

llvm_util/llvm2alive.cpp:53–63  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

51}
52
53FpExceptionMode parse_exceptions(llvm::Instruction &i) {
54 auto *fp = dyn_cast<llvm::ConstrainedFPIntrinsic>(&i);
55 if (!fp || !fp->getExceptionBehavior().has_value())
56 return {};
57 switch (*fp->getExceptionBehavior()) {
58 case llvm::fp::ebIgnore: return FpExceptionMode::Ignore;
59 case llvm::fp::ebMayTrap: return FpExceptionMode::MayTrap;
60 case llvm::fp::ebStrict: return FpExceptionMode::Strict;
61 default: UNREACHABLE();
62 }
63}
64
65FCmp::Cond parse_fcmp_cond(llvm::FCmpInst::Predicate pred) {
66 FCmp::Cond cond;

Callers 4

visitUnaryOperatorMethod · 0.85
visitBinaryOperatorMethod · 0.85
visitFCmpInstMethod · 0.85
visitIntrinsicInstMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected