Left: | ||
Right: |
LEFT | RIGHT |
---|---|
1 // Copyright (c) 2010 Google Inc. | 1 // Copyright (c) 2010 Google Inc. |
2 // All rights reserved. | 2 // All rights reserved. |
3 // | 3 // |
4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
6 // met: | 6 // met: |
7 // | 7 // |
8 // * Redistributions of source code must retain the above copyright | 8 // * Redistributions of source code must retain the above copyright |
9 // notice, this list of conditions and the following disclaimer. | 9 // notice, this list of conditions and the following disclaimer. |
10 // * Redistributions in binary form must reproduce the above | 10 // * Redistributions in binary form must reproduce the above |
(...skipping 28 matching lines...) Expand all Loading... | |
39 #include "common/dwarf_cu_to_module.h" | 39 #include "common/dwarf_cu_to_module.h" |
40 | 40 |
41 #include <assert.h> | 41 #include <assert.h> |
42 #if !defined(__ANDROID__) | 42 #if !defined(__ANDROID__) |
43 #include <cxxabi.h> | 43 #include <cxxabi.h> |
44 #endif | 44 #endif |
45 #include <inttypes.h> | 45 #include <inttypes.h> |
46 #include <stdio.h> | 46 #include <stdio.h> |
47 | 47 |
48 #include <algorithm> | 48 #include <algorithm> |
49 #if defined(_LIBCPP_VERSION) && defined(__linux__) | 49 #if defined(_LIBCPP_VERSION) |
Mark Mentovai
2014/07/07 18:15:28
I don’t think __linux__ is necessary. If you’re us
earthdok
2014/07/07 18:18:09
Done.
| |
50 // http://crbug.com/391792 | |
Mark Mentovai
2014/07/07 18:15:28
I think the #ifdef makes this obvious, you shouldn
earthdok
2014/07/07 18:18:09
Done.
| |
51 #include <unordered_set> | 50 #include <unordered_set> |
52 #else | 51 #else |
53 #include <tr1/unordered_set> | 52 #include <tr1/unordered_set> |
54 #endif | 53 #endif |
55 #include <utility> | 54 #include <utility> |
56 | 55 |
57 #include "common/dwarf_line_to_module.h" | 56 #include "common/dwarf_line_to_module.h" |
58 | 57 |
59 namespace google_breakpad { | 58 namespace google_breakpad { |
60 | 59 |
61 using std::map; | 60 using std::map; |
62 using std::pair; | 61 using std::pair; |
63 using std::sort; | 62 using std::sort; |
64 #if defined(_LIBCPP_VERSION) && defined(__linux__) | 63 #if defined(_LIBCPP_VERSION) |
65 // http://crbug.com/391792 | |
66 using std::unordered_set; | 64 using std::unordered_set; |
67 #else | 65 #else |
68 using std::tr1::unordered_set; | 66 using std::tr1::unordered_set; |
69 #endif | 67 #endif |
70 using std::vector; | 68 using std::vector; |
71 | 69 |
72 // Data provided by a DWARF specification DIE. | 70 // Data provided by a DWARF specification DIE. |
73 // | 71 // |
74 // In DWARF, the DIE for a definition may contain a DW_AT_specification | 72 // In DWARF, the DIE for a definition may contain a DW_AT_specification |
75 // attribute giving the offset of the corresponding declaration DIE, and | 73 // attribute giving the offset of the corresponding declaration DIE, and |
(...skipping 979 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1055 return dwarf_version >= 2; | 1053 return dwarf_version >= 2; |
1056 } | 1054 } |
1057 | 1055 |
1058 bool DwarfCUToModule::StartRootDIE(uint64 offset, enum DwarfTag tag) { | 1056 bool DwarfCUToModule::StartRootDIE(uint64 offset, enum DwarfTag tag) { |
1059 // We don't deal with partial compilation units (the only other tag | 1057 // We don't deal with partial compilation units (the only other tag |
1060 // likely to be used for root DIE). | 1058 // likely to be used for root DIE). |
1061 return tag == dwarf2reader::DW_TAG_compile_unit; | 1059 return tag == dwarf2reader::DW_TAG_compile_unit; |
1062 } | 1060 } |
1063 | 1061 |
1064 } // namespace google_breakpad | 1062 } // namespace google_breakpad |
LEFT | RIGHT |