ICE in push_reload for avr

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

ICE in push_reload for avr

Pitchumani Sivanupandi
Hi Johann,

There is an ICE in push_reload for AVR target which is very similar to
PR64452. Attached the test case (options: -mmcu=atmega1280 -O1).

PR64452's fix makes the virtual reloads in one chunk for push operation.
What is the significance to address the virtuals only in range of

I tried below split to load the symbol reference to register before
doing the arithmetic on it. This avoids the defect, but it is un-optimal
and may split RTLs for non-push operations also.

  [(set (match_operand:HI 0 "register_operand" "")
        (const:HI (plus:HI (match_operand:HI 1 "symbol_ref_operand" "")
                      (match_operand:ALL2 2 "immediate_operand" ""))))]
   && (REGNO (operands[0]) >= FIRST_VIRTUAL_REGISTER)"
  [(set (match_dup 0)
        (match_dup 1))
   (set (match_dup 0)
        (plus:HI (match_dup 0)
                 (match_dup 2)))])

Any suggestions?


AVR-GCC-list mailing list
[hidden email]

ice-reload-avr.c (243 bytes) Download Attachment