https://github.com/jmorse commented:

I suppose what this is encoding is a (subtle?) assumption about how 
definition-subprograms are modelled: they're created once  and are immutable. 
Wheras declaration-functions can be forwarded declared and then have extra 
information added to them when a definition is emitted. DIBuilder enforces this 
by refusing to let you re-set the retainedNodes of definition subprograms.

If there's no performance cost as a result of this patch, then it seems fine to 
go in to me., but is there a functional reason in a later patch that makes it 
necessary? Other folks might believe it's valuable to preserve the assumption 
about how debug-info is constructed within DIBuilder (CC @adrian-prantl 
@dwblaikie ). 

https://github.com/llvm/llvm-project/pull/139914
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to