diff options
author | Jiri Gaisler <jiri@gaisler.se> | 2019-01-25 16:40:29 +0100 |
---|---|---|
committer | Jiri Gaisler <jiri@gaisler.se> | 2019-01-25 16:40:29 +0100 |
commit | c553ccdd1edd6124a6643bb8e829d98fd636ef6e (patch) | |
tree | 12fdfe48d93209f45b2ea8f0ec674b2e721ad885 | |
parent | dd6a10dfe62992dd426dc22564412ad30269c210 (diff) |
covoar: wrong symbol length in coverage map
-rw-r--r-- | tester/covoar/ExecutableInfo.cc | 2 | ||||
-rw-r--r-- | tester/covoar/ObjdumpProcessor.cc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/tester/covoar/ExecutableInfo.cc b/tester/covoar/ExecutableInfo.cc index d93860b..c593e1d 100644 --- a/tester/covoar/ExecutableInfo.cc +++ b/tester/covoar/ExecutableInfo.cc @@ -47,7 +47,7 @@ namespace Coverage { for (auto& func : cu.get_functions()) { if (func.has_machine_code() && (!func.is_inlined() || func.is_external())) { createCoverageMap (cu.name(), func.name(), - func.pc_low(), func.pc_high()); + func.pc_low(), func.pc_high() - 1); } } } diff --git a/tester/covoar/ObjdumpProcessor.cc b/tester/covoar/ObjdumpProcessor.cc index 05507de..56ee219 100644 --- a/tester/covoar/ObjdumpProcessor.cc +++ b/tester/covoar/ObjdumpProcessor.cc @@ -36,7 +36,7 @@ namespace Coverage { uint32_t lowAddress = coverageMap.getFirstLowAddress(); uint32_t size = coverageMap.getSize(); - uint32_t highAddress = lowAddress + size; + uint32_t highAddress = lowAddress + size - 1; // If there are NOT already saved instructions, save them. SymbolInformation* symbolInfo = SymbolsToAnalyze->find( symbolName ); |