Skip to content

Commit 108b0a6

Browse files
r-barnesfacebook-github-bot
authored andcommitted
c10::optional -> std::optional in executorch/extension/llm/custom_ops/op_sdpa_aot.cpp
Summary: `c10::optional` is just an alias for `std::optional`. We are removing that alias, so we need to fix all instances where it is used. Differential Revision: D64648343
1 parent af13be9 commit 108b0a6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

extension/llm/custom_ops/op_sdpa_aot.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,11 +116,11 @@ at::Tensor custom_sdpa_aten(
116116
const int64_t start_pos,
117117
// @lint-ignore CLANGTIDY facebook-hte-ConstantArgumentPassByValue
118118
// @lint-ignore CLANGTIDY facebook-hte-ParameterMightThrowOnCopy
119-
const c10::optional<at::Tensor> attn_mask,
119+
const std::optional<at::Tensor> attn_mask,
120120
const double dropout_p,
121121
const bool is_causal,
122122
// @lint-ignore CLANGTIDY facebook-hte-ParameterMightThrowOnCopy
123-
const c10::optional<double> scale) {
123+
const std::optional<double> scale) {
124124
auto output = at::empty_like(q);
125125
WRAP_TO_ATEN(custom_sdpa_out_no_context, 8)
126126
(q, k, v, start_pos, attn_mask, dropout_p, is_causal, scale, output);

0 commit comments

Comments
 (0)