diff options
author | Xavier Leroy <xavier.leroy@inria.fr> | 2017-06-15 15:11:26 +0200 |
---|---|---|
committer | Bernhard Schommer <bschommer@users.noreply.github.com> | 2017-07-06 15:41:51 +0200 |
commit | dff22ef6d855973e0e0f05c7203a6bfa9a4cf01a (patch) | |
tree | 82c09b8cff023557084d6257acdef84b1311dd35 /x86/Asmexpand.ml | |
parent | 92fc8a425034abc1247203a4c0d471e8b6d0e941 (diff) | |
download | compcert-dff22ef6d855973e0e0f05c7203a6bfa9a4cf01a.tar.gz compcert-dff22ef6d855973e0e0f05c7203a6bfa9a4cf01a.zip |
Extend builtin arguments with a pointer addition operator
This extension enables more addressing modes to be encoded as builtin arguments and used in conjunction with volatile memory accesses.
Current status: x86 port only, the only new addressing mode handled is reg + offset.
Diffstat (limited to 'x86/Asmexpand.ml')
-rw-r--r-- | x86/Asmexpand.ml | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/x86/Asmexpand.ml b/x86/Asmexpand.ml index 8e69061e..1b716165 100644 --- a/x86/Asmexpand.ml +++ b/x86/Asmexpand.ml @@ -108,6 +108,8 @@ let addressing_of_builtin_arg = function | BA (IR r) -> linear_addr r Z.zero | BA_addrstack ofs -> linear_addr RSP (Integers.Ptrofs.unsigned ofs) | BA_addrglobal(id, ofs) -> global_addr id ofs + | BA_addptr(BA (IR r), BA_int n) -> linear_addr r (Integers.Int.signed n) + | BA_addptr(BA (IR r), BA_long n) -> linear_addr r (Integers.Int64.signed n) | _ -> assert false (* Handling of memcpy *) |