Re: [Sdcc-user] STM8: Incorrect optimization

2022-09-17 Thread Basil Hussain
On 17/09/2022 08:08, Philipp Klaus Krause wrote: Could you or Richard open a ticker in the bug tracker? I think Richard should be the one to do that, as he was the one who discovered the issue. Unless he does not have (or does not wish to create) a SourceForge account, in which case I am wi

Re: [Sdcc-user] STM8: Incorrect optimization

2022-09-17 Thread Philipp Klaus Krause
Am 14.09.22 um 21:34 schrieb Basil Hussain: I agree, parts of that assembly are weird. I don't think that code would work properly. Could you or Richard open a ticker in the bug tracker? Philipp ___ Sdcc-user mailing list Sdcc-user@lists.sourcef

Re: [Sdcc-user] STM8: Incorrect optimization

2022-09-14 Thread Basil Hussain
I agree, parts of that assembly are weird. I don't think that code would work properly. pusha ld (0x01, sp), a So, take the argument in A register, push it onto the stack ('cause we want to later use A to pass a value of zero in call to _tm1638_curs)... but then loa

[Sdcc-user] STM8: Incorrect optimization

2022-09-14 Thread Richard Hodges
I am updating my inline assembly code to work with the changes in 4.2 and have test code to verify the changes. This does not seem related to inline assembly, but what looks like an incorrect optimization. Here is the source: void test_number(char tnum) { disp_clear(); disp_curs(0); di