Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make Callable::call_argv_fast public #7315

Merged
merged 3 commits into from
Feb 1, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion src/Callable.h
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,6 @@ class Callable {

// Note that the first entry in argv must always be a JITUserContext*.
int call_argv_checked(size_t argc, const void *const *argv, const QuickCallCheckInfo *actual_cci) const;
int call_argv_fast(size_t argc, const void *const *argv) const;

using FailureFn = std::function<int(JITUserContext *)>;

Expand Down Expand Up @@ -380,6 +379,15 @@ class Callable {
};
}
}

/** Unsafe low-overhead way of invoking the Callable.
*
* This function relies on the same calling convention as the argv-based
* functions generated for ahead-of-time compiled Halide pilelines.
*
* \note The first argument in the first entry in argv must always be a JITUserContext*.
*/
int call_argv_fast(size_t argc, const void *const *argv) const;
};

} // namespace Halide
Expand Down