This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] MIPS: add mips32r2 patterns to generate ext and ins insns.

David Ung <> writes:
> ok..  here is the latest patch.  :)
> I will add a test case in a seperate patch.

The testcase is needed at the same time, sorry ;)


  (a) I said in the review that the extzv<mode> and insv<mode> patterns
      should use the "mips_use_ins_ext_p" function as their condition,
      because that would stop the optimisers from creating their own
      invalid patterns (through combination, etc.)  I notice that you've
      decided to just use ISA_HAS_EXT_INS instead.

  (b) I said in the second message that you should remove the TARGET_64BIT
      check from code like this:

> +       if (TARGET_64BIT && GET_MODE (operands[0]) == DImode)
> +         emit_insn (gen_extzvdi (operands[0], operands[1], operands[2],
> + 				operands[3]));
> +       else
> +         emit_insn (gen_extzvsi (operands[0], operands[1], operands[2],
> + 				operands[3]));
> +       DONE;

      because we shouldn't get here for DImode if !TARGET_64BIT.
      As written, the code implies that we sometimes want to generate
      extzvsi when operand[0] has DImode, which clearly isn't the case.

      I notice that you've decided to keep the test in the new code.

Was this just an oversight, or did you make a deliberate decision
not to do the above?  If the latter, what were the reasons?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]