aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Documentation
diff options
authorLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2017-08-16 09:52:54 +0200
committerLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2018-06-23 07:46:40 +0200
commitc6d4716f71de8de9683464b677207304583dc2a0 (patch)
tree9b49d056f48ae59fe666f75fe47aa8492090e0a3 /Documentation
parentd0694a238744b642714e7cd226193dd1365176d0 (diff)
downloadsparse-dev-c6d4716f71de8de9683464b677207304583dc2a0.tar.gz
cast: specialize FPCAST into [USF]CVTF
Currently, all casts to a floating point type use OP_FPCAST. This is maybe simple but rather uncovenient as it correspond to several quite different operations that later need extra checks. Change this by directly using different instructions for the different cases: - FCVTF for float-float conversions - UCVTF for unsigned integer to floats - SCVTF for signed integer to floats and reject attempts to cast a pointer to a float. Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/IR.rst12
1 files changed, 9 insertions, 3 deletions
diff --git a/Documentation/IR.rst b/Documentation/IR.rst
index 67ef06a5..38683a73 100644
--- a/Documentation/IR.rst
+++ b/Documentation/IR.rst
@@ -270,12 +270,18 @@ They all have the following signature:
.. op:: OP_SCAST
Cast to signed integer.
-.. op:: OP_FPCAST
- Cast to floating-point.
-
.. op:: OP_PTRCAST
Cast to pointer.
+.. op:: OP_UCVTF
+ Conversion from unsigned integer to float type.
+
+.. op:: OP_SCVTF
+ Conversion from signed integer to float type.
+
+.. op:: OP_FCVTF
+ Conversion between float types.
+
Ternary ops
-----------
.. op:: OP_SEL