Refactor to share map_info amongst threads.

Allow the use of the same map info to be shared when getting information on
multiple threads from the same pid.

Change-Id: I2e460e20154a10f4894ae563331fb32179e4551f
diff --git a/libbacktrace/Backtrace.h b/libbacktrace/Backtrace.h
index 00f0a10..d741ef1 100644
--- a/libbacktrace/Backtrace.h
+++ b/libbacktrace/Backtrace.h
@@ -45,7 +45,7 @@
 
 class BacktraceCurrent : public Backtrace {
 public:
-  BacktraceCurrent(BacktraceImpl* impl);
+  BacktraceCurrent(BacktraceImpl* impl, backtrace_map_info_t* map_info);
   virtual ~BacktraceCurrent();
 
   bool ReadWord(uintptr_t ptr, uint32_t* out_value);
@@ -53,14 +53,14 @@
 
 class BacktracePtrace : public Backtrace {
 public:
-  BacktracePtrace(BacktraceImpl* impl, pid_t pid, pid_t tid);
+  BacktracePtrace(BacktraceImpl* impl, pid_t pid, pid_t tid, backtrace_map_info_t* map_info);
   virtual ~BacktracePtrace();
 
   bool ReadWord(uintptr_t ptr, uint32_t* out_value);
 };
 
-Backtrace* CreateCurrentObj();
-Backtrace* CreatePtraceObj(pid_t pid, pid_t tid);
-Backtrace* CreateThreadObj(pid_t tid);
+Backtrace* CreateCurrentObj(backtrace_map_info_t* map_info);
+Backtrace* CreatePtraceObj(pid_t pid, pid_t tid, backtrace_map_info_t* map_info);
+Backtrace* CreateThreadObj(pid_t tid, backtrace_map_info_t* map_info);
 
 #endif // _LIBBACKTRACE_BACKTRACE_H