File tree Expand file tree Collapse file tree 1 file changed +2
-14
lines changed Expand file tree Collapse file tree 1 file changed +2
-14
lines changed Original file line number Diff line number Diff line change @@ -91,21 +91,9 @@ IntegerType IntegerType::scaleElementBitwidth(unsigned scale) {
9191// ===----------------------------------------------------------------------===//
9292
9393unsigned FloatType::getWidth () {
94- if (llvm::isa<Float8E5M2Type, Float8E4M3Type, Float8E4M3FNType,
95- Float8E5M2FNUZType, Float8E4M3FNUZType, Float8E4M3B11FNUZType,
96- Float8E3M4Type>(*this ))
97- return 8 ;
98- if (llvm::isa<Float16Type, BFloat16Type>(*this ))
99- return 16 ;
100- if (llvm::isa<Float32Type, FloatTF32Type>(*this ))
94+ if (llvm::isa<FloatTF32Type>(*this ))
10195 return 32 ;
102- if (llvm::isa<Float64Type>(*this ))
103- return 64 ;
104- if (llvm::isa<Float80Type>(*this ))
105- return 80 ;
106- if (llvm::isa<Float128Type>(*this ))
107- return 128 ;
108- llvm_unreachable (" unexpected float type" );
96+ return APFloat::semanticsSizeInBits (getFloatSemantics ());
10997}
11098
11199// / Returns the floating semantics for the given type.
You can’t perform that action at this time.
0 commit comments