<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-text-flowed" style="font-family: -moz-fixed;
font-size: 14px;" lang="x-unicode">> On 5/8/12 7:07 AM, Richard
Osborne wrote:
<br>
> > On 08/05/12 11:29, Ralf Karrenberg wrote:
<br>
> >> On 5/8/12 11:40 AM, Richard Osborne wrote:
<br>
> >>>> Cheers,
<br>
> >>>> Ralf
<br>
> >>>> /// hasAddressTaken - returns true if
there are any uses of this basic block
<br>
> >>>> /// other than direct branches,
switches, etc. to it.
<br>
> >>>> - bool hasAddressTaken() const { return
getSubclassDataFromValue() != 0; }
<br>
> >>>> + bool hasAddressTaken() const {
<br>
> >>>> + return
(getSubclassDataFromValue()& ~HasMetadataBit) != 0;
<br>
> >>>> + }
<br>
> >>> I think this will result in basic block metadata
effecting
<br>
> >>> optimizations. What would happen if you just
ignored metadata here?
<br>
> >> It will always treat a block that has metadata
attached as a block
<br>
> >> whose address has been taken, which results in a
crash at a later
<br>
> >> point (don't remember exactly where) because the
address was never taken.
<br>
>
<br>
> I think you might want to update the comment explaining what
you said
<br>
> above and providing a justification for it. Developers
misunderstanding
<br>
> code seems like a flag for a better comment, IMHO.
<br>
<br>
That makes sense. I attached the updated patch.
<br>
<br>
> -- John T.
<br>
>
<br>
> > Ah sorry, I totally misread this bit of the code. It
looks fine to me.
<br>
</div>
</body>
</html>