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
gaoqiong
MIGraphX
Commits
a374d441
Commit
a374d441
authored
Apr 10, 2019
by
Shucai Xiao
Browse files
clang format
parent
4e673ca3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
src/quantization.cpp
src/quantization.cpp
+7
-5
No files found.
src/quantization.cpp
View file @
a374d441
...
...
@@ -24,17 +24,19 @@ instruction_ref convert_fp32_fp16(program& prog, instruction_ref& ins)
instruction_ref
ins_fp16
{};
if
(
ins
->
name
()
==
"@literal"
)
{
shape
s
=
ins
->
get_shape
();
auto
l
=
ins
->
get_literal
();
if
(
s
.
type
()
==
shape
::
float_type
)
shape
s
=
ins
->
get_shape
();
auto
l
=
ins
->
get_literal
();
if
(
s
.
type
()
==
shape
::
float_type
)
{
auto
tv
=
l
.
get
<
const
float
>
();
ins_fp16
=
prog
.
add_literal
(
literal
({
shape
::
half_type
,
s
.
lens
()},
tv
.
begin
(),
tv
.
end
()));
ins_fp16
=
prog
.
add_literal
(
literal
({
shape
::
half_type
,
s
.
lens
()},
tv
.
begin
(),
tv
.
end
()));
}
else
{
auto
tv
=
l
.
get
<
const
double
>
();
ins_fp16
=
prog
.
add_literal
(
literal
({
shape
::
half_type
,
s
.
lens
()},
tv
.
begin
(),
tv
.
end
()));
ins_fp16
=
prog
.
add_literal
(
literal
({
shape
::
half_type
,
s
.
lens
()},
tv
.
begin
(),
tv
.
end
()));
}
}
else
if
(
ins
->
name
()
==
"@param"
)
...
...
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