[DTrace-devel] [PATCH 10/16] Export dt_cg_tramp_call_clauses() and dt_cg_tramp_return()
Eugene Loh
eugene.loh at oracle.com
Tue Mar 23 15:24:54 PDT 2021
Get rid of dt_cg_tramp_epilogue_advance(). It is used only by the
dtrace provider, and inlining the function into the provider makes the
structure clearer and better mimics what you are doing in pid.
Get rid of dt_cg_tramp_epilogue(). It comprises only two lines anyhow.
Inlining into the providers makes the structure clearer among the
various providers. Plus "epilogue" is kind of a weird name anyhow since
it contains the call_clauses, which does not feel like "epilogue" at all.
On 3/19/21 12:54 AM, Kris Van Hees wrote:
> This patch also makes the probe argument to dt_cg_tramp_call_clauses()
> const since that is what dt_probe_clause_iter() enforces.
>
> The dt_cg_tramp_call_clauses() and dt_cg_tramp_return() functions
> were only being used from dt_cg_tramp_epilogue() and its *_advance()
> variant. More complex providers have a need for calling them directly
> to have more control over the trampoline epilogue creation.
More information about the DTrace-devel
mailing list