From 83cc11add90eea576a798bacf821a70a28d4d9cc Mon Sep 17 00:00:00 2001 From: David Monniaux Date: Wed, 29 May 2019 00:25:01 +0200 Subject: to be able to use DDR we need 8-byte pointers in jump tables --- mppa_k1c/TargetPrinter.ml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'mppa_k1c') diff --git a/mppa_k1c/TargetPrinter.ml b/mppa_k1c/TargetPrinter.ml index 15f05960..96779517 100644 --- a/mppa_k1c/TargetPrinter.ml +++ b/mppa_k1c/TargetPrinter.ml @@ -173,10 +173,10 @@ module Target (*: TARGET*) = (* Associate labels to floating-point constants and to symbols. *) let print_tbl oc (lbl, tbl) = - fprintf oc " .balign 4\n"; + fprintf oc " .balign 8\n"; fprintf oc "%a:\n" label lbl; List.iter - (fun l -> fprintf oc " .4byte %a\n" + (fun l -> fprintf oc " .8byte %a\n" print_label l) tbl @@ -408,9 +408,9 @@ module Target (*: TARGET*) = fprintf oc "%s jumptable [ " comment; List.iter (fun l -> fprintf oc "%a " print_label l) tbl; fprintf oc "]\n"; - fprintf oc " make %a = %a\n ;;\n" ireg base_reg label lbl; - fprintf oc " lwz.xs %a = %a[%a]\n ;;\n" ireg base_reg ireg idx_reg ireg base_reg; - fprintf oc " igoto %a\n ;;\n" ireg base_reg; + fprintf oc " make %a = %a\n ;;\n" ireg base_reg label lbl; + fprintf oc " ld.xs %a = %a[%a]\n ;;\n" ireg base_reg ireg idx_reg ireg base_reg; + fprintf oc " igoto %a\n ;;\n" ireg base_reg; section oc Section_jumptable; print_tbl oc (lbl, tbl); section oc Section_text -- cgit