Actions
Bug #41
closedfixing a register allocation problem in the compiler
Start date:
04/23/2015
Due date:
% Done:
0%
Estimated time:
Forum topic:
Description
The following procedure produces a trap in the compiler.
PROCEDURE P(IN in : ARRAY 10 OF SHORTCHAR; OUT out : ARRAY 10 OF SHORTCHAR); BEGIN out[Index()] := SHORT(CHR(1 + ORD(in[0]))); END P;
The reason is that the right hand side expression is evaluated into a register
that cannot be used for a comparison operation, which is necessary for SHORTCHAR conversion.
A proposal to fix the bug exists in CPC 1.7 rc5 by changing
the register selection order.
Reported/fix proposed by oberoncore, Maliya by dia, 2013-05-19.
See http://forum.oberoncore.ru/viewtopic.php?f=47&t=4087&p=80212#p80205
http://oberspace.dyndns.org/index.php?topic=500.0;topicseen
Refers to CPC 1.7 rc5 change list number 17.
Actions