From 5c3aa03eceb8ba45eb635d1e7cbb742b709aac7b Mon Sep 17 00:00:00 2001 From: YamaArashi Date: Tue, 18 Oct 2016 00:23:50 -0700 Subject: fix bug with -fhex-asm and negative integers --- gcc/final.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gcc') diff --git a/gcc/final.c b/gcc/final.c index a886f87..87f9641 100755 --- a/gcc/final.c +++ b/gcc/final.c @@ -2670,14 +2670,14 @@ output_addr_const (file, x) if (GET_CODE (XEXP (x, 0)) == CONST_INT) { output_addr_const (file, XEXP (x, 1)); - if (INTVAL (XEXP (x, 0)) >= 0) + if (INTVAL (XEXP (x, 0)) >= 0 || flag_hex_asm) fprintf (file, "+"); output_addr_const (file, XEXP (x, 0)); } else { output_addr_const (file, XEXP (x, 0)); - if (INTVAL (XEXP (x, 1)) >= 0) + if (INTVAL (XEXP (x, 1)) >= 0 || flag_hex_asm) fprintf (file, "+"); output_addr_const (file, XEXP (x, 1)); } -- cgit v1.2.3