aboutsummaryrefslogtreecommitdiffstats
path: root/arm/Asmexpand.ml
diff options
context:
space:
mode:
authorBernhard Schommer <bernhardschommer@gmail.com>2015-10-09 16:36:16 +0200
committerBernhard Schommer <bernhardschommer@gmail.com>2015-10-09 16:36:16 +0200
commitb0c47e12f2bbff0905ad853b90169df16d87f6be (patch)
tree701518c70bd10e60f9add5d8e6e53731ba77bf81 /arm/Asmexpand.ml
parent6a2cfdb1bc410532a23c58206cd00b39bc7ccba3 (diff)
downloadcompcert-kvx-b0c47e12f2bbff0905ad853b90169df16d87f6be.tar.gz
compcert-kvx-b0c47e12f2bbff0905ad853b90169df16d87f6be.zip
Filled in missing functions for debug information on ia32.
Like for arm and ppc the functions for section names and start and end addresses of compilation units are defined and the print_annot function is moved to Asmexpandaux.ml.
Diffstat (limited to 'arm/Asmexpand.ml')
-rw-r--r--arm/Asmexpand.ml25
1 files changed, 2 insertions, 23 deletions
diff --git a/arm/Asmexpand.ml b/arm/Asmexpand.ml
index b5bbc664..990f207d 100644
--- a/arm/Asmexpand.ml
+++ b/arm/Asmexpand.ml
@@ -407,38 +407,17 @@ let float_reg_to_dwarf = function
| FR8 -> 72 | FR9 -> 73 | FR10 -> 74 | FR11 -> 75
| FR12 -> 76 | FR13 -> 77 | FR14 -> 78 | FR15 -> 79
-let preg_to_dwarf_int = function
+let preg_to_dwarf = function
| IR r -> int_reg_to_dwarf r
| FR r -> float_reg_to_dwarf r
| _ -> assert false
-let translate_annot annot =
- let rec aux = function
- | BA x -> Some (13,BA (preg_to_dwarf_int x))
- | BA_int _
- | BA_long _
- | BA_float _
- | BA_single _
- | BA_loadglobal _
- | BA_addrglobal _
- | BA_loadstack _ -> None
- | BA_addrstack ofs -> Some (13,BA_addrstack ofs)
- | BA_splitlong (hi,lo) ->
- begin
- match (aux hi,aux lo) with
- | Some (_,hi) ,Some (_,lo) -> Some (13,BA_splitlong (hi,lo))
- | _,_ -> None
- end in
- (match annot with
- | [] -> None
- | a::_ -> aux a)
-
let expand_function id fn =
try
set_current_function fn;
if !Clflags.option_g then
- expand_debug id translate_annot expand_instruction fn.fn_code
+ expand_debug id 13 preg_to_dwarf expand_instruction fn.fn_code
else
List.iter expand_instruction fn.fn_code;
Errors.OK (get_current_function ())