summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/SymbolFile/DWARF
diff options
context:
space:
mode:
authorPavel Labath <labath@google.com>2016-11-01 16:11:14 +0000
committerPavel Labath <labath@google.com>2016-11-01 16:11:14 +0000
commit1408bf7231c22bce70fea5470a865955ee40399b (patch)
tree353d7fa675051c51596081e7a66d6a8efd027877 /lldb/source/Plugins/SymbolFile/DWARF
parentb187f5d988e95197e4b8cfa2121ee13c292ad8bc (diff)
downloadbcm5719-llvm-1408bf7231c22bce70fea5470a865955ee40399b.tar.gz
bcm5719-llvm-1408bf7231c22bce70fea5470a865955ee40399b.zip
Remove TimeValue usage from FileSpec.h
Summary: The only usage there was in GetModificationTime(). I also took the opportunity to move this function from FileSpec to the FileSystem class - since we are using FileSpecs to also represent remote files for which we cannot (easily) retrieve modification time, it makes sense to make the decision to get the modification time more explicit. The new function returns a llvm::sys::TimePoint<>. To aid the transition from TimeValue, I have added a constructor to it which enables implicit conversion from a time_point. Reviewers: zturner, clayborg Subscribers: mehdi_amini, tberghammer, danalbert, beanz, mgorny, lldb-commits Differential Revision: https://reviews.llvm.org/D25392 llvm-svn: 285702
Diffstat (limited to 'lldb/source/Plugins/SymbolFile/DWARF')
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp3
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h1
2 files changed, 3 insertions, 1 deletions
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
index 6a1b6b423fb..f843824703c 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
@@ -21,6 +21,7 @@
#include "lldb/Core/RangeMap.h"
#include "lldb/Core/RegularExpression.h"
#include "lldb/Core/Section.h"
+#include "lldb/Host/FileSystem.h"
//#define DEBUG_OSO_DMAP // DO NOT CHECKIN WITH THIS NOT COMMENTED OUT
#if defined(DEBUG_OSO_DMAP)
@@ -424,7 +425,7 @@ Module *SymbolFileDWARFDebugMap::GetModuleByCompUnitInfo(
FileSpec oso_file(oso_path, false);
ConstString oso_object;
if (oso_file.Exists()) {
- TimeValue oso_mod_time(oso_file.GetModificationTime());
+ TimeValue oso_mod_time(FileSystem::GetModificationTime(oso_file));
if (oso_mod_time != comp_unit_info->oso_mod_time) {
obj_file->GetModule()->ReportError(
"debug map object file '%s' has changed (actual time is "
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h
index ffc9fed353a..8cef57b4a95 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h
@@ -14,6 +14,7 @@
#include <vector>
#include "lldb/Core/RangeMap.h"
+#include "lldb/Host/TimeValue.h"
#include "lldb/Symbol/SymbolFile.h"
#include "UniqueDWARFASTType.h"
OpenPOWER on IntegriCloud