[PATCH] Set a debugger "target" to guide DWARF choices
Paul Robinson
Paul_Robinson at playstation.sony.com
Fri Jun 26 00:16:19 PDT 2015
================
Comment at: lib/CodeGen/AsmPrinter/DwarfDebug.cpp:222-223
@@ -212,3 +221,4 @@
+
// Turn on accelerator tables for Darwin by default, pubnames by
- // default for non-Darwin/PS4, and handle split dwarf.
+ // default for GDB, and handle split dwarf.
if (DwarfAccelTables == Default)
----------------
echristo wrote:
> Feel free to update this comment separately.
Hm? The comment update reflects the code change for setting HasDwarfPubSections (line 235). Did you have something else in mind?
================
Comment at: lib/CodeGen/AsmPrinter/DwarfDebug.cpp:245
@@ -234,3 +244,3 @@
// Everybody else uses GNU's.
- UseGNUTLSOpcode = !(IsDarwin || IsPS4) || DwarfVersion < 3;
+ UseGNUTLSOpcode = !(IsDarwin || TT.isPS4CPU()) || DwarfVersion < 3;
----------------
echristo wrote:
> I don't like the use of TT.isPS4CPU() here on first look, can you explain a bit?
IsPS4 had been a bool field in the class, but as it was never used outside the constructor that seemed unnecessary so I removed it.
I capture the triple once (line 212) as it's not all that cheap, and lets me decide about PS4 as well as FreeBSD (see lines 214 and 216).
I could capture IsPS4 as a local bool if you'd prefer, as I do make that test twice, but isPS4CPU() is relatively cheap so it didn't seem worthwhile.
http://reviews.llvm.org/D8506
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
More information about the llvm-commits
mailing list