[llvm-commits] PATCH: BasicBlock metadata

Ralf Karrenberg karrenberg at cdl.uni-saarland.de
Tue May 8 05:48:43 PDT 2012


Hi,

please find the second revision of the block metadata patch attached.

Cheers,
Ralf

----- Original Message -----
> From: "Richard Osborne" <richard at xmos.com>
> To: "Ralf Karrenberg" <karrenberg at cdl.uni-saarland.de>
> Cc: llvm-commits at cs.uiuc.edu
> Sent: Dienstag, 8. Mai 2012 14:07:26
> Subject: Re: [llvm-commits] PATCH: BasicBlock metadata
> 
> On 08/05/12 11:29, Ralf Karrenberg wrote:
> > On 5/8/12 11:40 AM, Richard Osborne wrote:
> >>> Cheers,
> >>> Ralf
> >>>     /// hasAddressTaken - returns true if there are any uses of
> >>>     this basic block
> >>>     /// other than direct branches, switches, etc. to it.
> >>> -  bool hasAddressTaken() const { return
> >>> getSubclassDataFromValue() != 0; }
> >>> +  bool hasAddressTaken() const {
> >>> +    return (getSubclassDataFromValue()&  ~HasMetadataBit) != 0;
> >>> +  }
> >> I think this will result in basic block metadata effecting
> >> optimizations. What would happen if you just ignored metadata
> >> here?
> > It will always treat a block that has metadata attached as a block
> > whose address has been taken, which results in a crash at a later
> > point (don't remember exactly where) because the address was never
> > taken.
> Ah sorry, I totally misread this bit of the code. It looks fine to
> me.
> 
> --
> Richard Osborne | XMOS
> http://www.xmos.com
> 
> 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: basicblock_metadata.patch
Type: text/x-patch
Size: 26121 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120508/af49605f/attachment.bin>


More information about the llvm-commits mailing list