[PATCH] D46917: [Fixed Point Arithmetic] Comparison and Unary Operations for Fixed Point Types
Bevin Hansson via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed May 23 01:41:34 PDT 2018
ebevhan added inline comments.
================
Comment at: lib/CodeGen/CGExprScalar.cpp:2141
+ case BuiltinType::ShortAccum:
+ fbits = BUILTIN_SACCUM_FBIT;
+ break;
----------------
Please see my comments on other patches about these values.
================
Comment at: lib/CodeGen/CGExprScalar.cpp:2178
+ llvm::Value *amt =
+ llvm::ConstantInt::get(value->getType(), 1 << fbits,
+ /*isSigned=*/type->isSignedFixedPointType());
----------------
Use an APInt with the right size here instead of relying on types in the compiler.
Repository:
rC Clang
https://reviews.llvm.org/D46917
More information about the cfe-commits
mailing list