hubert.reinterpretcast added a comment.

In D150221#4343546 <https://reviews.llvm.org/D150221#4343546>, @efriedma wrote:

> It's not unprecedented to add flags to copy the behavior of other compilers, 
> to make porting easier, especially when it doesn't place much burden on 
> compiler maintainers.  But what compiler preserves the names/values of static 
> variables by default?  It's not the sort of feature I'd expect anyone to 
> advertise.  And we don't really want to encourage people to use global flags 
> for this sort of thing; applying behavior everywhere has weird effects, and 
> users often don't understand the flags they're using.

This is an adaptation of the IBM XL compiler's `-qstatsym` option, which is 
meant to generate symbol table entries for static variables. An artifact of 
that compiler is that static variables are often not discarded even when 
unused. We attempt to achieve the combined effect using 
`-fkeep-static-variables`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D150221/new/

https://reviews.llvm.org/D150221

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to