[PATCH] Move the name pointer off of Value

Owen Anderson resistor at mac.com
Wed Jun 3 19:52:31 PDT 2015


+llvm-commits as well

> On Jun 3, 2015, at 7:40 PM, Owen Anderson <resistor at mac.com> wrote:
> 
> 
>> On Jun 3, 2015, at 5:52 PM, Chandler Carruth <chandlerc at gmail.com <mailto:chandlerc at gmail.com>> wrote:
>> 
>> Anyone there?
>> 
>> I'm still really unhappy at this going in, I don't think it's necessarily
>> the right tradeoff at all.
>> 
>> 
>> REPOSITORY
>>  rL LLVM
>> 
>> http://reviews.llvm.org/D10173 <http://reviews.llvm.org/D10173>
>> 
>> EMAIL PREFERENCES
>>  http://reviews.llvm.org/settings/panel/emailpreferences/
> 
> 
> I replied to the message ~45 minutes after you sent it.  I’ve reproduced it below.  I’ll add that since then Benny Kramer expressed support for the change on llvm-commits.
> 
> —Owen
> 
> 
>>> On Jun 1, 2015, at 4:15 PM, Chandler Carruth <chandlerc at gmail.com <mailto:chandlerc at gmail.com>> wrote:
>>> 
>>> Uh, folks, please discuss this more widely before just committing. This is
>>> a really significant change and has implications you're not really
>>> addressing at all. Clang is not the only frontend and not the only producer
>>> of value names. With this change you'll likely cause a significant compile
>>> time hit for many folks.
>> 
>> I would strongly argue that anyone using named Values doesn’t care about compile time, or else they would already have stopped using named Values.
>> 
>> That said, I did some measurements for completeness.  I took the same stress IR file and used opt -metarenamer to add names to every value.   I measured opt -O2, best result out of five runs for each:
>> 
>> With my patch
>> 	No names
>> 		18.852s
>> 	Names
>> 		19.453s
>> Without my patch
>> 	No names
>> 		18.834s
>> 	Names
>> 		19.059s
>> 
>> In summary, the performance with names enabled degrades by approximately 2%, meaning that the degradation is approximately 1:1 with the memory savings in the not-advised-if-you-care-about-compile-time case.   In the without-names scenario, I would need to do more thorough measurement to be confident that I can even reliably distinguish any change.
>> 
>> —Owen
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150603/4f410ab5/attachment.html>


More information about the llvm-commits mailing list