diff options
author | Bernhard Schommer <bernhardschommer@gmail.com> | 2016-11-25 11:06:15 +0100 |
---|---|---|
committer | Bernhard Schommer <bernhardschommer@gmail.com> | 2016-11-25 11:06:15 +0100 |
commit | e8f2ef5c8c926462277afb520cacaa265b7e612c (patch) | |
tree | 7c3b552108da1d8fb3ae867e0076ab91663e7fa9 /x86/Asmexpand.ml | |
parent | 9521c220e157632972387ad0394010e89eff0aab (diff) | |
download | compcert-e8f2ef5c8c926462277afb520cacaa265b7e612c.tar.gz compcert-e8f2ef5c8c926462277afb520cacaa265b7e612c.zip |
Do not use hardcoded register number for sp.
Since the dwarf register names for x86_32 and x86_64 differ it is
wrong to hardcode the dwarf register number for rsp to 4.
Bug 20461
Diffstat (limited to 'x86/Asmexpand.ml')
-rw-r--r-- | x86/Asmexpand.ml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/x86/Asmexpand.ml b/x86/Asmexpand.ml index 0436bc86..90dc0e69 100644 --- a/x86/Asmexpand.ml +++ b/x86/Asmexpand.ml @@ -618,7 +618,7 @@ let expand_function id fn = try set_current_function fn; if !Clflags.option_g then - expand_debug id 4 preg_to_dwarf expand_instruction fn.fn_code + expand_debug id (int_reg_to_dwarf RSP) preg_to_dwarf expand_instruction fn.fn_code else List.iter expand_instruction fn.fn_code; Errors.OK (get_current_function ()) |