This is the mail archive of the gcc@gcc.gnu.org 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]

[RFA] Which is better? More and simplier patterns? Fewer patternswith more embedded code?


Back when I modified gcc 2.95.3 to produce PIC code for NetBSD/vax, I changed
the patterns in vax.md to be more specific with the instructions that got
matched.  The one advantage (to me as the writer) was it made it much easier
to track down what pattern caused what instruction to be emitted.

For instance:

(define_insn "*pushal"
  [(set (match_operand:SI 0 "push_operand" "=g")
        (match_operand:SI 0 "address_operand" "p"))]
  ""
  "pushal %a1")

I like the more and simplier patterns approach but I'm wondering what
the general recommendation is?
-- 
Matt Thomas                     email: matt@3am-software.com
3am Software Foundry              www: http://3am-software.com/bio/matt/
Cupertino, CA              disclaimer: I avow all knowledge of this message.


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