From patchwork Wed Jul 21 12:00:52 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [ARM,PING] : Remove superfluous test in arm_function_arg X-Patchwork-Submitter: John Tytgat X-Patchwork-Id: 59434 Message-Id: <527b493a51.Jo@hobbes.bass-software.com> To: gcc-patches@gcc.gnu.org Cc: nickc@redhat.com, richard.earnshaw@arm.com, paul@codesourcery.com Date: Wed, 21 Jul 2010 13:00:52 +0100 From: John Tytgat List-Id: In message <678f613751.Jo@hobbes.bass-software.com> John Tytgat wrote: > Attached patch removes in arm_function_arg() a superfluous test on one > of its parameters as that test is already done at the beginning of the > routine and the parameter doesn't change during the function. Gentle reminder ping. In the meanwhile I've found another superfluous test in arm_override_options(). Updated patch attached. gcc/ John Tytgat * config/arm/arm.c (arm_function_arg): Remove superfluous test. (arm_override_options): Likewise. Please commit after positive review. John. Index: config/arm/arm.c =================================================================== --- config/arm/arm.c (revision 162370) +++ config/arm/arm.c (working copy) @@ -1526,9 +1526,6 @@ if (TARGET_ARM && TARGET_CALLEE_INTERWORKING) warning (0, "enabling callee interworking support is only meaningful when compiling for the Thumb"); - if (TARGET_ARM && TARGET_CALLER_INTERWORKING) - warning (0, "enabling caller interworking support is only meaningful when compiling for the Thumb"); - if (TARGET_APCS_STACK && !TARGET_APCS_FRAME) { warning (0, "-mapcs-stack-check incompatible with -mno-apcs-frame"); @@ -4479,10 +4476,6 @@ && arm_needs_doubleword_align (mode, type)) pcum->nregs++; - if (mode == VOIDmode) - /* Pick an arbitrary value for operand 2 of the call insn. */ - return const0_rtx; - /* Only allow splitting an arg between regs and memory if all preceding args were allocated to regs. For args passed by reference we only count the reference pointer. */