From 2be7388ca0a5a44ec62b1202a6ef35754d676c23 Mon Sep 17 00:00:00 2001 From: Jeffrey A Law Date: Fri, 26 Feb 1999 01:11:21 +0000 Subject: [PATCH] reg-stack.c (subst_stack_regs_pat): Abort if the destination of a FP conditional move is not on the FP register stack. Sun Jan 17 03:20:47 1999 H.J. Lu (hjl@gnu.org) * reg-stack.c (subst_stack_regs_pat): Abort if the destination of a FP conditional move is not on the FP register stack. From-SVN: r25453 --- gcc/ChangeLog | 4 ++++ gcc/reg-stack.c | 8 +++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 5baf042cfb1b..7910d1c48cd8 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,9 @@ Fri Feb 26 01:47:46 1999 Jeffrey A Law (law@cygnus.com) + Sun Jan 17 03:20:47 1999 H.J. Lu (hjl@gnu.org) + * reg-stack.c (subst_stack_regs_pat): Abort if the destination + of a FP conditional move is not on the FP register stack. + * Makefile.in (compare, gnucompare): We do not care about comparison failures for objc/linking.o either. diff --git a/gcc/reg-stack.c b/gcc/reg-stack.c index a7a5fb7cd902..d92a1f95eceb 100644 --- a/gcc/reg-stack.c +++ b/gcc/reg-stack.c @@ -2349,6 +2349,10 @@ subst_stack_regs_pat (insn, regstack, pat) break; case IF_THEN_ELSE: + /* dest has to be on stack. */ + if (get_hard_regnum (regstack, *dest) < FIRST_STACK_REG) + abort (); + /* This insn requires the top of stack to be the destination. */ /* If the comparison operator is an FP comparison operator, @@ -2402,9 +2406,7 @@ subst_stack_regs_pat (insn, regstack, pat) } } - /* Make dest the top of stack. Add dest to regstack if not present. */ - if (get_hard_regnum (regstack, *dest) < FIRST_STACK_REG) - regstack->reg[++regstack->top] = REGNO (*dest); + /* Make dest the top of stack. */ SET_HARD_REG_BIT (regstack->reg_set, REGNO (*dest)); replace_reg (dest, FIRST_STACK_REG); -- 2.47.2