mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Backtracing] Add ImageMap instead of just using an Array.
We want to be able to efficiently serialise lists of images, and to do so it makes most sense to create a separate `ImageMap` type. This also provides a useful place to put methods to e.g. find an image by address or by build ID. rdar://124913332
This commit is contained in:
@@ -69,7 +69,7 @@ class Target {
|
||||
var crashingThread: TargetThread.ThreadID
|
||||
|
||||
var task: task_t
|
||||
var images: [Backtrace.Image] = []
|
||||
var images: ImageMap
|
||||
|
||||
var threads: [TargetThread] = []
|
||||
var crashingThreadNdx: Int = -1
|
||||
@@ -193,7 +193,7 @@ class Target {
|
||||
|
||||
mcontext = mctx
|
||||
|
||||
images = Backtrace.captureImages(for: task)
|
||||
images = ImageMap.capture(for: task)
|
||||
|
||||
fetchThreads(limit: limit, top: top, cache: cache, symbolicate: symbolicate)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user