[clang] [DO NOT MERGE][clang][RISCV] Introduce OFP8(E4M3, E5M2) RISC-V vector types (PR #191349)
Craig Topper via cfe-commits
cfe-commits at lists.llvm.org
Fri Apr 10 10:13:42 PDT 2026
================
@@ -327,9 +331,13 @@ void RVVType::initTypeStr() {
Str += getTypeString("int");
break;
case ScalarTypeKind::UnsignedInteger:
+ Str += getTypeString("uint");
+ break;
case ScalarTypeKind::FloatE4M3:
+ Str += Twine("vfloat8e4m3" + LMUL.str() + "_t").str();
+ break;
case ScalarTypeKind::FloatE5M2:
- Str += getTypeString("uint");
+ Str += Twine("vfloat8e5m2" + LMUL.str() + "_t").str();
----------------
topperc wrote:
I don't think the Twine is giving any benefit here. The std::string is constructed before the Twine is created. The Twine only holds a single std::string. Maybe you meant something like `(Twine("vfloat8e5m2") + LMUL + "_t").str()`?
https://github.com/llvm/llvm-project/pull/191349
More information about the cfe-commits
mailing list