On Sun, Oct 13, 2019 at 3:43 AM Jonas Maebe <jo...@freepascal.org> wrote:

> The snippet came from the compiled program. It showed that the "while
> true do ;" infinite loop got removed by the peephole optimiser (as also
> mentioned by Martin). That was wrong. The peephole optimiser does not
> perform any dead code analyses. It's only supposed to transform code
> patterns into equivalent (but hopefully faster) ones.
>
> Adding a "v:=2;" statement at the start of the program, which would make
> the loop reachable, did not affect the generated code (i.e., the loop
> was still removed).
>
>
> Jonas
>

Ah, I get it now.  So basically my comment to them on the tracker issue was
just kind of focusing on the wrong thing. Now I know for next time, at
least. Thanks!
_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply via email to