From f122a053a6268d46af1405a5cbf813d3a90ab8f9 Mon Sep 17 00:00:00 2001 From: Greta Yorsh <45005955+gretay-js@users.noreply.github.com> Date: Wed, 17 Nov 2021 14:50:59 +0000 Subject: [PATCH] Fix "make check_all_arches" in ocaml/ subdirectory (#388) --- ocaml/asmcomp/arm/emit.mlp | 2 ++ ocaml/asmcomp/arm64/emit.mlp | 4 ++++ ocaml/asmcomp/power/emit.mlp | 4 ++++ ocaml/asmcomp/riscv/emit.mlp | 2 ++ ocaml/asmcomp/s390x/emit.mlp | 2 ++ 5 files changed, 14 insertions(+) diff --git a/ocaml/asmcomp/arm/emit.mlp b/ocaml/asmcomp/arm/emit.mlp index 4f638d3537e..57a16539d8a 100644 --- a/ocaml/asmcomp/arm/emit.mlp +++ b/ocaml/asmcomp/arm/emit.mlp @@ -769,6 +769,8 @@ let emit_instr i = assert false end | Lop (Iname_for_debugger _) -> 0 + | Lop (Iprobe _ |Iprobe_is_enabled _) -> + Misc.fatal_error ("Probes not supported.") | Lreloadretaddr -> let n = frame_size() in ` ldr lr, [sp, #{emit_int(n-4)}]\n`; 1 diff --git a/ocaml/asmcomp/arm64/emit.mlp b/ocaml/asmcomp/arm64/emit.mlp index 23bec3fde56..3cf7bba59e6 100644 --- a/ocaml/asmcomp/arm64/emit.mlp +++ b/ocaml/asmcomp/arm64/emit.mlp @@ -532,6 +532,8 @@ module BR = Branch_relaxation.Make (struct | Lop (Ispecific (Ibswap _)) -> 1 | Lop (Ispecific Imove32) -> 1 | Lop (Iname_for_debugger _) -> 0 + | Lop (Iprobe _ |Iprobe_is_enabled _) -> + Misc.fatal_error ("Probes not supported.") | Lreloadretaddr -> 0 | Lreturn -> epilogue_size () | Llabel _ -> 0 @@ -880,6 +882,8 @@ let emit_instr i = assert false end | Lop (Iname_for_debugger _) -> () + | Lop (Iprobe _ |Iprobe_is_enabled _) -> + Misc.fatal_error ("Probes not supported.") | Lreloadretaddr -> () | Lreturn -> diff --git a/ocaml/asmcomp/power/emit.mlp b/ocaml/asmcomp/power/emit.mlp index 681a7659b95..4aba2fbcf37 100644 --- a/ocaml/asmcomp/power/emit.mlp +++ b/ocaml/asmcomp/power/emit.mlp @@ -498,6 +498,8 @@ module BR = Branch_relaxation.Make (struct | Lop(Iintoffloat) -> 4 | Lop(Ispecific _) -> 1 | Lop (Iname_for_debugger _) -> 0 + | Lop (Iprobe _ |Iprobe_is_enabled _) -> + Misc.fatal_error ("Probes not supported.") | Lreloadretaddr -> 2 | Lreturn -> 2 | Llabel _ -> 0 @@ -859,6 +861,8 @@ let emit_instr i = let instr = name_for_specific sop in ` {emit_string instr} {emit_reg i.res.(0)}, {emit_reg i.arg.(0)}, {emit_reg i.arg.(1)}, {emit_reg i.arg.(2)}\n` | Lop (Iname_for_debugger _) -> () + | Lop (Iprobe _ |Iprobe_is_enabled _) -> + Misc.fatal_error ("Probes not supported.") | Lreloadretaddr -> ` {emit_string lg} 11, {emit_int(retaddr_offset())}(1)\n`; ` mtlr 11\n` diff --git a/ocaml/asmcomp/riscv/emit.mlp b/ocaml/asmcomp/riscv/emit.mlp index 2f8582148d8..1a7f067f9af 100644 --- a/ocaml/asmcomp/riscv/emit.mlp +++ b/ocaml/asmcomp/riscv/emit.mlp @@ -443,6 +443,8 @@ let emit_instr i = ` {emit_string instr} {emit_reg i.res.(0)}, {emit_reg i.arg.(0)}, {emit_reg i.arg.(1)}, {emit_reg i.arg.(2)}\n` | Lop (Iname_for_debugger _) -> () + | Lop (Iprobe _ |Iprobe_is_enabled _) -> + Misc.fatal_error ("Probes not supported.") | Lreloadretaddr -> let n = frame_size () in reload_ra n diff --git a/ocaml/asmcomp/s390x/emit.mlp b/ocaml/asmcomp/s390x/emit.mlp index bd08fd2967f..208812daea3 100644 --- a/ocaml/asmcomp/s390x/emit.mlp +++ b/ocaml/asmcomp/s390x/emit.mlp @@ -544,6 +544,8 @@ let emit_instr i = let instr = name_for_specific sop in ` {emit_string instr} {emit_reg i.res.(0)}, {emit_reg i.arg.(0)}, {emit_reg i.arg.(1)}\n` | Lop (Iname_for_debugger _) -> () + | Lop (Iprobe _ |Iprobe_is_enabled _) -> + Misc.fatal_error ("Probes not supported.") | Lreloadretaddr -> let n = frame_size() in ` lg %r14, {emit_int(n - size_addr)}(%r15)\n`