[PATCH] D109950: [Clang] Enable IC/IF mode for __ibm128
John McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 27 21:13:20 PDT 2021
rjmccall added inline comments.
================
Comment at: clang/include/clang/AST/ASTContext.h:44
#include "clang/Basic/TargetCXXABI.h"
+#include "clang/Basic/TargetInfo.h"
#include "clang/Basic/XRayLists.h"
----------------
It's a shame to have to do this in such a pervasively-included header as `ASTContext.h`. Can we make `TargetInfo::RealType` an `enum class` at namespace scope, so that we can just forward-declare it in this file?
This would also be a good opportunity to rename the enum to something like `ModeTypeKind`.
If we do that, it should be a separate patch, so that this can just be the `__ibm128` functionality change.
================
Comment at: clang/lib/Basic/TargetInfo.cpp:300
+ if (ExplicitType == Ibm128 || ExplicitType == LongDouble)
+ return ExplicitType;
break;
----------------
`__ibm128` is target-specific, right? So this should return `NoFloat` if someone requests `IF` or `IC` and the target doesn't support it, just like we do when the target doesn't support `KF`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D109950/new/
https://reviews.llvm.org/D109950
More information about the cfe-commits
mailing list