From 30dd806dedbfad8462f382494bebc2e99dd53071 Mon Sep 17 00:00:00 2001 From: kenner Date: Mon, 1 Jan 1996 02:26:06 +0000 Subject: [PATCH] (assign_temp): Add extra arg, DONT_PROMOTE. Don't return (const_int 0) for VOIDmode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@10923 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/function.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gcc/function.c b/gcc/function.c index 7d103c33f36..66ff42091b6 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -922,13 +922,16 @@ assign_stack_temp (mode, size, keep) /* Assign a temporary of given TYPE. KEEP is as for assign_stack_temp. MEMORY_REQUIRED is 1 if the result must be addressable stack memory; - it is 0 if a register is OK. */ + it is 0 if a register is OK. + DONT_PROMOTE is 1 if we should not promote values in register + to wider modes. */ rtx -assign_temp (type, keep, memory_required) +assign_temp (type, keep, memory_required, dont_promote) tree type; int keep; int memory_required; + int dont_promote; { enum machine_mode mode = TYPE_MODE (type); int unsignedp = TREE_UNSIGNED (type); @@ -952,11 +955,9 @@ assign_temp (type, keep, memory_required) return tmp; } - if (mode == VOIDmode) - return const0_rtx; - #ifndef PROMOTE_FOR_CALL_ONLY - mode = promote_mode (type, mode, &unsignedp, 0); + if (! dont_promote) + mode = promote_mode (type, mode, &unsignedp, 0); #endif return gen_reg_rtx (mode); -- 2.11.0