Details
- Reviewers
steven.zhang jsji nemanjai hubert.reinterpretcast jdoerfert - Group Reviewers
Restricted Project - Commits
- rG3fca6a7844b5: [Clang] Don't adjust align for IBM extended double
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/lib/CodeGen/TargetInfo.cpp | ||
---|---|---|
5055 | s/which is/which are/; and use getFloatTypeSemantics to reuse logic (including the possible need to handle OpenMP host versus device differences): } else if (Ty->isRealFloatingType() && getContext().getFloatTypeSemantics(Ty) == &llvm::APFloat::IEEEquad()) { // IEEE 128-bit floating numbers are also stored in vector registers, which // are quad-word aligned. return CharUnits::fromQuantity(16); } |
clang/lib/CodeGen/TargetInfo.cpp | ||
---|---|---|
5055 | It would be better to add a testcase for OpenMP host/device format mismatch. | |
5058 | I think it is better to refer to ABI rules instead of referring to vector registers. Section 2.2.3.3. Optional Save Areas If extended precision floating-point values in IEEE BINARY 128 QUADRUPLE PRECISION format are supported, map them to a single quadword, quadword aligned. This might result in skipped doublewords in the Parameter Save Area. |
Address comments
- Update comment to refer to ABI
- Add test case for OpenMP host & target mismatch
clang/test/CodeGen/ppc64le-varargs-f128.c | ||
---|---|---|
8 | Generally %clang is only used in test/Driver and %clang_cc1 should be used for tests. %clang_cc1 has a lit substitution rule to find the builtin include directory where stdarg.h can be found. |
clang/test/CodeGen/ppc64le-varargs-f128.c | ||
---|---|---|
8 | Thanks! I moved it in rG222da77a |
clang/test/CodeGen/ppc64le-varargs-f128.c | ||
---|---|---|
8 | rG222da77a82d17cbc6b989779e2ba2bb4904bb672 looks more wrong to me: test/Driver tests how the clang driver passes CC1 options to the frontend. The CodeGen should be tested in this directory. You probably should split %clang to several %clang_cc1 commands and keep the test here. |
clang/test/CodeGen/ppc64le-varargs-f128.c | ||
---|---|---|
8 | Ah, thanks for pointing it out. I simplified the splitted commands from clang -v. https://reviews.llvm.org/D92544 is created for easier view, if that looks fine, I'll commit it :-) |
s/which is/which are/;
and
use getFloatTypeSemantics to reuse logic (including the possible need to handle OpenMP host versus device differences):