We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ed5bd23 commit a00761fCopy full SHA for a00761f
mlir/lib/Dialect/EmitC/IR/EmitC.cpp
@@ -17,6 +17,7 @@
17
#include "llvm/ADT/STLExtras.h"
18
#include "llvm/ADT/TypeSwitch.h"
19
#include "llvm/Support/Casting.h"
20
+#include "llvm/Support/Compiler.h"
21
22
using namespace mlir;
23
using namespace mlir::emitc;
@@ -114,11 +115,8 @@ bool mlir::emitc::isIntegerIndexOrOpaqueType(Type type) {
114
115
bool mlir::emitc::isSupportedFloatType(Type type) {
116
if (auto floatType = llvm::dyn_cast<FloatType>(type)) {
117
switch (floatType.getWidth()) {
- case 16: {
118
- if (llvm::isa<Float16Type, BFloat16Type>(type))
119
- return true;
120
- return false;
121
- }
+ case 16:
+ return llvm::isa<Float16Type, BFloat16Type>(type);
122
case 32:
123
case 64:
124
return true;
0 commit comments