summaryrefslogtreecommitdiffstats
path: root/libunwindstack/tests/UnwinderTest.cpp
diff options
context:
space:
mode:
authorChristopher Ferris <cferris@google.com>2017-10-24 15:36:00 -0700
committerChristopher Ferris <cferris@google.com>2017-10-24 15:45:59 -0700
commit1cb84cea2f622327d41abb8845e97dffa055fa4e (patch)
treef6eee63bebccee922592de7b3946d4aab564475e /libunwindstack/tests/UnwinderTest.cpp
parent09123383cbdaee9ca0a85289061b7b98ff6160d8 (diff)
downloadcore-1cb84cea2f622327d41abb8845e97dffa055fa4e.tar.gz
core-1cb84cea2f622327d41abb8845e97dffa055fa4e.tar.bz2
core-1cb84cea2f622327d41abb8845e97dffa055fa4e.zip
Add an interface for stopping in certain maps.
Also, change the std::set parameters to std::vector. As jmgao points out, a small std::set is not really the best choice for performance reasons. Test: All unit tests pass, enabled the new unwinder and did a kill -3 on Test: an android process. Change-Id: I81227d7b79a9b7cf1d54fb0e3331d3cf4d4d3c4f
Diffstat (limited to 'libunwindstack/tests/UnwinderTest.cpp')
-rw-r--r--libunwindstack/tests/UnwinderTest.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/libunwindstack/tests/UnwinderTest.cpp b/libunwindstack/tests/UnwinderTest.cpp
index 83844732c..8a90baec0 100644
--- a/libunwindstack/tests/UnwinderTest.cpp
+++ b/libunwindstack/tests/UnwinderTest.cpp
@@ -308,8 +308,8 @@ TEST_F(UnwinderTest, verify_frames_skipped) {
ElfInterfaceFake::FakePushStepData(StepData(0, 0, true));
Unwinder unwinder(64, &maps_, &regs_, process_memory_);
- std::set<std::string> skip_set{"libunwind.so", "libanother.so"};
- unwinder.Unwind(&skip_set);
+ std::vector<std::string> skip_libs{"libunwind.so", "libanother.so"};
+ unwinder.Unwind(&skip_libs);
ASSERT_EQ(3U, unwinder.NumFrames());
@@ -572,7 +572,7 @@ TEST_F(UnwinderTest, map_ignore_suffixes) {
ElfInterfaceFake::FakePushStepData(StepData(0, 0, true));
Unwinder unwinder(64, &maps_, &regs_, process_memory_);
- std::set<std::string> suffixes{"oat"};
+ std::vector<std::string> suffixes{"oat"};
unwinder.Unwind(nullptr, &suffixes);
ASSERT_EQ(2U, unwinder.NumFrames());