Hi Roman,
On 2/21/20 3:49 PM, Roman Zhuykov wrote:
11.02.2020 14:00, Richard Earnshaw (lists) wrote:
+(define_insn "*doloop_end"
+ [(parallel [(set (pc)
+ (if_then_else
+ (ne (reg:SI LR_REGNUM) (const_int 1))
+ (label_ref (match_operand 0 "" ""))
+ (pc)))
+ (set (reg:SI LR_REGNUM)
+ (plus:SI (reg:SI LR_REGNUM) (const_int -1)))])]
+ "TARGET_32BIT && TARGET_HAVE_LOB && !flag_modulo_sched"
+ "le\tlr, %l0")
Is it deliberate that this pattern name has a '*' prefix? doloop_end
is a named expansion pattern according to md.texi.
R.
21.02.2020 18:30, Kyrill Tkachov wrote:
+;; Originally expanded by 'doloop_end'.
+(define_insn "doloop_end_internal"
We usually prefer to name these patterns with a '*' in front to
prevent the gen* machinery from generating gen_* unneeded expanders
for them if they're not used.
It seems you and Richard asking Andrea to do the opposite things.
:) LOL.patch
Almost, but not exactly incompatible things ;)
doloop_end is a standard name and if we wanted to use it directly it
cannot have a '*', which Richard is right to point out.
Once "doloop_end" is moved to its own expander and the define_insn is
doloop_end_internal, there is no reason for it to not have a '*' as its
gen_* form is never called.
Thanks,
Kyrill
Roman
PS. I don't have an idea what approach is correct.