[PATCH] D41044: Implementation of -fextend-lifetimes and -fextend-this-ptr to aid with debugging of optimized code

2018-11-26 Thread Wolfgang Pieb via Phabricator via cfe-commits
wolfgangp updated this revision to Diff 175307. wolfgangp added a comment. Rebased on r347577 with some test cases. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D41044/new/ https://reviews.llvm.org/D41044 Files: include/clang/Driver/Options.td

[PATCH] D41044: Implementation of -fextend-lifetimes and -fextend-this-ptr to aid with debugging of optimized code

2017-12-20 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. I have some results from the development build of our kernel ('-O2 -g -flto'). According to dwarfdump -statistics, when compiled with -fextend-lifetimes, the percentage of covered scope bytes increases from 62% to 69%. The number of inlined scopes decreases by 4%, and (I

[PATCH] D41044: Implementation of -fextend-lifetimes and -fextend-this-ptr to aid with debugging of optimized code

2017-12-11 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. I should note we've had at least one request to make this specifiable per-function, which would mean defining an attribute to control the emission of the fake-use intrinsics. Doing the feature that way would be consistent with 'optnone'.

[PATCH] D41044: Implementation of -fextend-lifetimes and -fextend-this-ptr to aid with debugging of optimized code

2017-12-11 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a project: debug-info. vsk added a comment. Thanks for your patches @wolfgangp! I agree with Eli that we should evaluate enabling this automatically with -Og. I'll test this out on a few internal projects and report back. https://reviews.llvm.org/D41044

[PATCH] D41044: Implementation of -fextend-lifetimes and -fextend-this-ptr to aid with debugging of optimized code

2017-12-08 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. This might be something we want to turn on automatically for -Og. https://reviews.llvm.org/D41044 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D41044: Implementation of -fextend-lifetimes and -fextend-this-ptr to aid with debugging of optimized code

2017-12-08 Thread Wolfgang Pieb via Phabricator via cfe-commits
wolfgangp added a comment. A quick note on usage: Compile your source with "clang -O2 -g -c -fextend-lifetimes foo.cpp" to see the effects (or use -fextend-this-ptr if you just want to extend the lifetime of 'this'). https://reviews.llvm.org/D41044

[PATCH] D41044: Implementation of -fextend-lifetimes and -fextend-this-ptr to aid with debugging of optimized code

2017-12-08 Thread Wolfgang Pieb via Phabricator via cfe-commits
wolfgangp created this revision. Herald added a subscriber: JDevlieghere. The patch implements the clang support for generating artificial uses of local variables and parameters to aid with debugging of optimized code. I presented this concept in my lightning talk "Debugging of optimized code: