summaryrefslogtreecommitdiff
path: root/src/passes/Print.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/passes/Print.cpp')
-rw-r--r--src/passes/Print.cpp16
1 files changed, 13 insertions, 3 deletions
diff --git a/src/passes/Print.cpp b/src/passes/Print.cpp
index ede49ab38..aca43924d 100644
--- a/src/passes/Print.cpp
+++ b/src/passes/Print.cpp
@@ -548,13 +548,19 @@ struct PrintExpressionContents
if (curr->bytes == 1) {
o << '8';
} else if (curr->bytes == 2) {
- o << "16";
+ if (curr->type == Type::f32) {
+ o << "_f16";
+ } else {
+ o << "16";
+ }
} else if (curr->bytes == 4) {
o << "32";
} else {
abort();
}
- o << (curr->signed_ ? "_s" : "_u");
+ if (curr->type != Type::f32) {
+ o << (curr->signed_ ? "_s" : "_u");
+ }
}
restoreNormalColor(o);
printMemoryName(curr->memory, o, wasm);
@@ -575,7 +581,11 @@ struct PrintExpressionContents
if (curr->bytes == 1) {
o << '8';
} else if (curr->bytes == 2) {
- o << "16";
+ if (curr->valueType == Type::f32) {
+ o << "_f16";
+ } else {
+ o << "16";
+ }
} else if (curr->bytes == 4) {
o << "32";
} else {