Skip to content

Commit a59ca03

Browse files
authored
【CUDA Kernel No.46】cvm算子Kernel修复 -part (#75703)
* Add gpu/cvm_kernel.h * CI
1 parent 8f6b9df commit a59ca03

File tree

2 files changed

+30
-0
lines changed

2 files changed

+30
-0
lines changed

paddle/phi/kernels/gpu/cvm_kernel.cu

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
// limitations under the License.
1414

1515
#pragma once
16+
#include "paddle/phi/kernels/gpu/cvm_kernel.h"
1617
#include "paddle/phi/backends/gpu/gpu_primitives.h"
1718
#include "paddle/phi/core/kernel_registry.h"
1819
#include "paddle/phi/kernels/funcs/eigen/common.h"
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
// Copyright (c) 2024 PaddlePaddle Authors. All Rights Reserved.
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#pragma once
16+
17+
#include "paddle/phi/core/dense_tensor.h"
18+
#include "paddle/phi/core/kernel_registry.h"
19+
20+
namespace phi {
21+
22+
template <typename T, typename Context>
23+
void CVMCUDAKernel(const Context& dev_ctx,
24+
const DenseTensor& x_in,
25+
const DenseTensor& cvm,
26+
bool use_cvm,
27+
DenseTensor* out);
28+
29+
} // namespace phi

0 commit comments

Comments
 (0)