Updated ColdFire toolchain sources available on my CVS server
Peter Barada
peter@the-baradas.com
Sun Aug 15 03:54:00 GMT 2004
>>> If anyone else has seen reproducable ICEs from the ColdFire compiler,
>>> I really want to know(including a testcase).
>>>
>>Found another (or the same :) type of ICE ?
>>Preprocessed C source and log file attached.
>>
>>C/Diagnostika_main.c:173: error: insn does not satisfy its constraints:
>>(insn 156 485 157 6 0x4018539c (set (mem/s:HI (plus:SI (reg:SI 9 %a1)
>> (const_int 20 [0x14])) [22 <variable>.FAT_cnt+0 S2 A16])
>> (mem:HI (plus:SI (reg/f:SI 14 %a6)
>> (reg:SI 0 %d0)) [53 file_cnt S4 A16])) 35 {*m68k.md:1076} (nil)
>> (nil))
>
>
>Nope, that is the first one that I asked for. In this case the
>compiler is trying to do a move using mode 6 source addressing and
>mode 5 destination addressing, something that the ColdFire pattern
>should do but insn't.
Hmm, This is a illegal combination of addressing modes. ColdFire doesn't
support mode 6 source and mode 5 destination. In fact if mode 6 is
the souce addressing mode, then the destination can only be mode 1-4,
and if mode 6 is the destination then the source can only be mode
1-4. This isn't going to be easy to fix since the predicate operators
only deal with one side of the move. What I need is a predicate(or
condition) that can access all of the operands of the instruction;
something like:
(define_insn "*movhi_cf"
[(set (match_operand:HI 0 "nonimmediate_operand" "=r<Q>,g,U")
(match_operand:HI 1 "general_operand" "g,r<Q>,U"))]
"TARGET_COLDFIRE && !TARGET_CFV4 &&
m68k_valid_move_operands(operands[0] && operands[1])"
"* return output_move_himode (operands);")
Where the 'valid_move_operands(operands[0], operands[1])' would return false
for illegal combinations of operands/addressing modes for the move
instruction which would reject the pattern and cause the comiler to
try another tack.
--
Peter Barada
peter@the-baradas.com
------
Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com
More information about the crossgcc
mailing list