aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/config/arm/arm.c4
2 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index c75cbe0..2330d33 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2003-11-18 Roger Sayle <roger@eyesopen.com>
+
+ PR middle-end/11821
+ * config/arm/arm.c (arm_rtx_costs_1): Improve estimate of the code
+ size for calls to libgcc's div & mod subroutines when using -Os.
+
2003-11-18 Jan Hubicka <jh@suse.cz>
* cgraph.c (change_decl_assembler_name): Avoid bogus warnings.
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index 15143d9..c0a0cd84 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -3210,7 +3210,9 @@ arm_rtx_costs_1 (rtx x, enum rtx_code code, enum rtx_code outer)
case DIV:
case MOD:
- return 100;
+ case UDIV:
+ case UMOD:
+ return optimize_size ? COSTS_N_INSNS (2) : 100;
case ROTATE:
if (mode == SImode && GET_CODE (XEXP (x, 1)) == REG)