These two AppleThreadPlanStepThrough thread plans have parameterized behavior
that is unutilized. To make their interface and implementation simpler, this
change inlines those outside parameters.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
I can't think of a really good reason why you would need to override the general "step in avoids nodebug" behavior. I'm pretty sure I was thinking of a trampoline that got you half way to somewhere interesting, at which point you would want to negotiate again for the trampoline to take you the rest of the way. In that case you would not want to obey the general setting. But this setting controls what happens when you don't find a good place to go, so that control isn't necessary.
It still seems to me like a trampoline which knew that to implement itself, all it had to do was a couple of stepi's - for instance if a dyld stub knew that the stub had been filled in and would jump straight to the target, it could run without letting the other threads go. That's actually something the dyld stubs could figure out, they just don't at present. So I'd rather not remove this control.
Happy to restore the stop_others parameter, but for my understanding I have two questions:
- Is the behavior you envision something that applies to these specific thread plan subclasses (ie not dyld stubs)
- Will callers decide to stop others from the outside, or is the decision to stop others something that these subclasses would make internally?
Good questions. I was reading this incorrectly. This is the enqueuing plan telling the StepThrough plan whether to stop others. That actually seems like a bad thing to do, since the enqueuer can't really know whether it is actually safe to stop others while running the enqueued plan. These should go.
This is one parameter being inlined.