[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread JF Bastien via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. jfb marked an inline comment as done. Closed by commit rL346915: CGDecl::emitStoresForConstant fix synthesized constant's name (authored by jfb, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM

[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread JF Bastien via Phabricator via cfe-commits
jfb marked an inline comment as done. jfb added inline comments. Comment at: lib/CodeGen/CGDecl.cpp:990-998 + std::string Name = ("__const." + FunctionName(D.getParentFunctionOrMethod()) + + "." + D.getName()) + .str(); + llvm::Glob

[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 174090. jfb added a comment. - Inline the name creating, save a heap allocation. Repository: rC Clang https://reviews.llvm.org/D54055 Files: lib/CodeGen/CGDecl.cpp test/CodeGen/decl.c test/CodeGen/dump-struct-builtin.c test/CodeGenCXX/amdgcn-string-l

[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: lib/CodeGen/CGDecl.cpp:990-998 + std::string Name = ("__const." + FunctionName(D.getParentFunctionOrMethod()) + + "." + D.getName()) + .str(); + llvm::GlobalVariable *InsertBefore = null

[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. Small update to use `std::string` because `Twine` lifetimes are sad. This didn't trigger on any of the tests, but did in a stage2 build. Repository: rC Clang https://reviews.llvm.org/D54055 ___ cfe-commits mailing list cfe-c

[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-14 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 174087. jfb added a comment. Herald added a subscriber: jkorous. - Fix lifetime of the name, Twine bites again. Repository: rC Clang https://reviews.llvm.org/D54055 Files: lib/CodeGen/CGDecl.cpp test/CodeGen/decl.c test/CodeGen/dump-struct-builtin.c

[PATCH] D54055: CGDecl::emitStoresForConstant fix synthesized constant's name

2018-11-13 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. Seems reasonable to me. Repository: rC Clang https://reviews.llvm.org/D54055 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http: