I mirrored the text in the clang language extensions document as closely as possible.
Details
Diff Detail
- Repository
- rL LLVM
Event Timeline
docs/LangRef.rst | ||
---|---|---|
10864 ↗ | (On Diff #56858) | I'm not sure that we need to special case "mathematically correct". Why not say something like: "the first result is the operation modulo 2^bitwidth, and the second result is 1 iff the operation overflowed." A more pertinent bit of information here is what is defined to be an overflow: an operation overflows if for any N, "ext(A op B) to iN != (ext(A) to iN) op (ext(B) to iN)" where ext is sext for sign overflow and zext for unsigned overflow. |
docs/LangRef.rst | ||
---|---|---|
10864 ↗ | (On Diff #56858) | Sure. I had been aiming for wording congruent with the clang manual, if we give up on that it's possible to say things a bit better. |
lgtm, with an optional-to-fix nit
docs/LangRef.rst | ||
---|---|---|
10863 ↗ | (On Diff #57004) | What I had in mind was: Each of these intrinsics returns a two-element struct. The first element of this struct contains the result of the corresponding arithmetic operation modulo 2\ :sup:`n`\ , where n is the bit width of the result. I.e. I don't see a need to special case the overflow or no-overflow But I'm okay with what you have. |