diff options
author | Cyril SIX <cyril.six@kalray.eu> | 2019-07-24 11:05:56 +0200 |
---|---|---|
committer | Cyril SIX <cyril.six@kalray.eu> | 2019-07-24 11:05:56 +0200 |
commit | a11f3b87e0535b6c7953c74d00d91fb7d7fbb21b (patch) | |
tree | f93d402a71f8113d5bef927ccf2177fec1a5747b /mppa_k1c/PrintOp.ml | |
parent | 7da1af080217eef5626480ac30feda45ff8ca002 (diff) | |
download | compcert-kvx-a11f3b87e0535b6c7953c74d00d91fb7d7fbb21b.tar.gz compcert-kvx-a11f3b87e0535b6c7953c74d00d91fb7d7fbb21b.zip |
(#145) Fix <bad addressing> on RTL dumps
Diffstat (limited to 'mppa_k1c/PrintOp.ml')
-rw-r--r-- | mppa_k1c/PrintOp.ml | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mppa_k1c/PrintOp.ml b/mppa_k1c/PrintOp.ml index 7c408cdf..67f87000 100644 --- a/mppa_k1c/PrintOp.ml +++ b/mppa_k1c/PrintOp.ml @@ -222,8 +222,9 @@ let print_operation reg pp op = match op with | _, _ -> fprintf pp "<bad operator>" let print_addressing reg pp = function - | Aindexed n, [r1] -> fprintf pp "%a + %Ld" reg r1 (camlint64_of_ptrofs n) + | Aindexed2XS scale, [r1;r2] -> fprintf pp "%a + (%a << %ld)" reg r1 reg r2 (camlint_of_coqint scale) | Aindexed2, [r1;r2] -> fprintf pp "%a + %a" reg r1 reg r2 + | Aindexed n, [r1] -> fprintf pp "%a + %Ld" reg r1 (camlint64_of_ptrofs n) | Aglobal(id, ofs), [] -> fprintf pp "\"%s\" + %Ld" (extern_atom id) (camlint64_of_ptrofs ofs) | Ainstack ofs, [] -> fprintf pp "stack(%Ld)" (camlint64_of_ptrofs ofs) |