Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jerrrrry
infinicore
Commits
94280d85
Commit
94280d85
authored
Sep 16, 2025
by
wooway777
Browse files
issue/434 - added bf16 support for Cambricon MLU
parent
f9d16628
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
src/infiniccl/cambricon/infiniccl_cambricon.cc
src/infiniccl/cambricon/infiniccl_cambricon.cc
+4
-3
No files found.
src/infiniccl/cambricon/infiniccl_cambricon.cc
View file @
94280d85
...
...
@@ -25,6 +25,8 @@ inline cnclDataType_t getCnclDtype(infiniDtype_t datatype) {
return
cnclFloat32
;
case
INFINI_DTYPE_F16
:
return
cnclFloat16
;
case
INFINI_DTYPE_BF16
:
return
cnclBfloat16
;
default:
std
::
cerr
<<
"Unsupported data type: "
<<
datatype
<<
std
::
endl
;
std
::
abort
();
...
...
@@ -89,9 +91,7 @@ infiniStatus_t allReduce(
infinicclComm_t
comm
,
infinirtStream_t
stream
)
{
if
(
datatype
!=
INFINI_DTYPE_F32
&&
datatype
!=
INFINI_DTYPE_F16
)
{
return
INFINI_STATUS_BAD_PARAM
;
}
CHECK_DTYPE
(
datatype
,
INFINI_DTYPE_F32
,
INFINI_DTYPE_F16
,
INFINI_DTYPE_BF16
);
CHECK_CNCL
(
cnclAllReduce
(
sendbuf
,
recvbuf
,
count
,
getCnclDtype
(
datatype
),
getCnclRedOp
(
op
),
getCnclComm
(
comm
),
...
...
@@ -99,4 +99,5 @@ infiniStatus_t allReduce(
return
INFINI_STATUS_SUCCESS
;
}
}
// namespace infiniccl::cambricon
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment