llvm-project/clang/lib
Vedant Kumar 77dfca88b2 [CodeGen] Handle mixed-width ops in mixed-sign mul-with-overflow lowering
The special lowering for __builtin_mul_overflow introduced in r320902
fixed an ICE seen when passing mixed-sign operands to the builtin.

This patch extends the special lowering to cover mixed-width, mixed-sign
operands. In a few common scenarios, calls to muloti4 will no longer be
emitted.

This should address the latest comments in PR34920 and work around the
link failure seen in:

  https://bugzilla.redhat.com/show_bug.cgi?id=1657544

Testing:
- check-clang
- A/B output comparison with: https://gist.github.com/vedantk/3eb9c88f82e5c32f2e590555b4af5081

Differential Revision: https://reviews.llvm.org/D55843

llvm-svn: 349542
2018-12-18 21:05:03 +00:00
..
ARCMigrate Misc typos fixes in ./lib folder 2018-12-10 12:37:46 +00:00
AST [ExprConstant] Handle compound assignment when LHS has integral type and RHS has floating point type 2018-12-18 07:38:06 +00:00
ASTMatchers [ASTImporter] Fix redecl chain of classes and class templates 2018-12-17 12:42:12 +00:00
Analysis [analyzer] Fix some expressions staying live too long. Add a debug checker. 2018-12-16 23:44:06 +00:00
Basic Basic: make `int_least64_t` and `int_fast64_t` match on Darwin 2018-12-12 17:05:20 +00:00
CodeGen [CodeGen] Handle mixed-width ops in mixed-sign mul-with-overflow lowering 2018-12-18 21:05:03 +00:00
CrossTU [ASTImporter] Add importer specific lookup 2018-12-17 13:53:12 +00:00
Driver [Driver][PS4] Do not implicitly link against asan or ubsan if -nostdlib or -nodefaultlibs on PS4. 2018-12-18 17:03:35 +00:00
Edit [Fixed Point Arithmetic] Fixed Point to Boolean Cast 2018-10-23 17:55:35 +00:00
Format [clang-format] Do not treat asm clobber [ as ObjCExpr, refined 2018-11-22 14:49:55 +00:00
Frontend Automatic variable initialization 2018-12-18 05:12:21 +00:00
FrontendTool [analyzer][NFC] Merge ClangCheckerRegistry to CheckerRegistry 2018-12-15 18:11:49 +00:00
Headers [Builltins][X86] Provide implementations of __lzcnt16, __lzcnt, __lzcnt64 for MS compatibility. Remove declarations from intrin.h and implementations from lzcntintrin.h 2018-12-14 00:21:02 +00:00
Index [OpenCL] Add generic AS to 'this' pointer 2018-12-13 10:15:27 +00:00
Lex Misc typos fixes in ./lib folder 2018-12-10 12:37:46 +00:00
Parse Fix up diagnostics. 2018-12-14 03:35:10 +00:00
Rewrite Misc typos fixes in ./lib folder 2018-12-10 12:37:46 +00:00
Sema Emit -Wformat properly for bit-field promotions. 2018-12-18 15:54:38 +00:00
Serialization Fix up diagnostics. 2018-12-14 03:35:10 +00:00
StaticAnalyzer [analyzer] MoveChecker: Squash the bit field because it causes a GCC warning. 2018-12-17 21:07:38 +00:00
Tooling Add explicit dependency on clangSerialization for a bunch of components to fix -DBUILD_SHARED_LIBS=on build 2018-12-12 08:02:18 +00:00
CMakeLists.txt Add Cross Translation Unit support library 2017-09-22 11:11:01 +00:00