<div dir="ltr">This was my mess-up (see previous email). Sorry for the noise.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Mar 10, 2014 at 9:30 AM, Simon Peyton Jones <span dir="ltr"><<a href="mailto:simonpj@microsoft.com" target="_blank">simonpj@microsoft.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">That doesn't look right.  Are you using -O?<br>
<br>
If so, perhaps open a ticket explaining how to reproduce, and including the results of -ddump-cmm.<br>
<br>
(Don't use module Main, because it's irrelevant to this question, and generate a certain amount of auxiliary goop.)<br>
<br>
Thanks<br>
<span class="HOEnZb"><font color="#888888"><br>
SImon<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
| -----Original Message-----<br>
| From: ghc-devs [mailto:<a href="mailto:ghc-devs-bounces@haskell.org">ghc-devs-bounces@haskell.org</a>] On Behalf Of Karel<br>
| Gardas<br>
| Sent: 09 March 2014 21:40<br>
| To: Johan Tibell<br>
| Cc: <a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a><br>
| Subject: Re: Optimized Cmm containing useless blocks<br>
|<br>
|<br>
| If I may add to this, then I'm curious why there is something like:<br>
|<br>
|   I64[BaseReg + 784] = I64[BaseReg + 784];<br>
|<br>
| presented in Cmm optimized code. Since I don't know Cmm enough I've<br>
| verified if the semantics is really C like by looking into generated asm<br>
| and indeed it looks so. This costs 5 isns of sparc asm btw.<br>
|<br>
| If someone is interested to duplicate this, then use sparc or ppc 32 bit<br>
| registerised target and Haskell code:<br>
|<br>
| module Main where<br>
|<br>
| import Data.Int<br>
|<br>
| main = print ( ( 2 ^ 6 ) :: Int64 )<br>
|<br>
| Karel<br>
|<br>
| On 03/ 8/14 09:21 AM, Johan Tibell wrote:<br>
| > While looking at some generated Cmm I saw things like this<br>
| ><br>
| > c1Cm:<br>
| >      goto c1Cq;<br>
| > c1Cq:<br>
| ><br>
| > i.e. useless basic blocks that haven't been optimized away. Is this to<br>
| > be expected?<br>
| ><br>
| > -- Johan<br>
| ><br>
| ><br>
| ><br>
| > _______________________________________________<br>
| > ghc-devs mailing list<br>
| > <a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a><br>
| > <a href="http://www.haskell.org/mailman/listinfo/ghc-devs" target="_blank">http://www.haskell.org/mailman/listinfo/ghc-devs</a><br>
|<br>
| _______________________________________________<br>
| ghc-devs mailing list<br>
| <a href="mailto:ghc-devs@haskell.org">ghc-devs@haskell.org</a><br>
| <a href="http://www.haskell.org/mailman/listinfo/ghc-devs" target="_blank">http://www.haskell.org/mailman/listinfo/ghc-devs</a><br>
</div></div></blockquote></div><br></div>