| 63 | |
| 64 | // Holder for an i128 value, and a boolean indicating overflow. |
| 65 | class ValueWithOverflow { |
| 66 | public: |
| 67 | ValueWithOverflow(llvm::Value* value, llvm::Value* overflow) |
| 68 | : value_(value), overflow_(overflow) {} |
| 69 | |
| 70 | // Make from IR struct |
| 71 | static ValueWithOverflow MakeFromStruct(DecimalIR* decimal_ir, llvm::Value* dstruct); |
| 72 | |
| 73 | // Build a corresponding IR struct |
| 74 | llvm::Value* AsStruct(DecimalIR* decimal_ir) const; |
| 75 | |
| 76 | llvm::Value* value() const { return value_; } |
| 77 | llvm::Value* overflow() const { return overflow_; } |
| 78 | |
| 79 | private: |
| 80 | llvm::Value* value_; |
| 81 | llvm::Value* overflow_; |
| 82 | }; |
| 83 | |
| 84 | // Holder for an i128 value that is split into two i64s |
| 85 | class ValueSplit { |
no outgoing calls
no test coverage detected