Changes

Summary

  1. [Test] Clear out br i1 undef from tests to avoid UB (details)
  2. Revert "[CodeGen] Don't create fake FunctionDecls when generating block/byref" (details)
  3. [LoopDeletion] Exploit undef Phi inputs when symbolically executing 1st iteration (details)
  4. [M68k] Refactor codegen patterns for logic operations and add tests for it (details)
  5. [M68k] Add testcases for shift and rotate instructions (details)
  6. [M68k] Fix incorrect #include-ed file in M68kSubtarget (details)
Commit 976926e8ee3e3c9f7c391281eab89e0d1b02092a by mkazantsev
[Test] Clear out br i1 undef from tests to avoid UB

We don't want to test possible unexpected impact of such
branches. Replacing them with regular conditions. Idea by
Nikita Popov.
The file was modifiedllvm/test/Transforms/LoopDeletion/eval_first_iteration.ll
Commit f681fd927e883301658dcac9a78109ee0aba12a8 by zequanwu
Revert "[CodeGen] Don't create fake FunctionDecls when generating block/byref"

That commit causes crash with error "!dbg attachment points at wrong subprogram for function" on iOS platforms.

This reverts commit f4c06bcb67a1eba13a7f164961586dddaf8ebd5f.
The file was modifiedclang/test/CodeGenObjC/debug-info-block-helper.m
The file was modifiedclang/lib/CodeGen/CGBlocks.cpp
The file was modifiedclang/test/CodeGenCXX/debug-info-blocks.cpp
The file was modifiedclang/test/CodeGenObjC/debug-info-blocks.m
Commit 842b4c83cb751d5f371ba27881fc92fdbd38d850 by mkazantsev
[LoopDeletion] Exploit undef Phi inputs when symbolically executing 1st iteration

Follow-up on Roman's idea expressed in D103959.
- If a Phi has undefined inputs from live blocks:
   - and no other inputs, assume it is undef itself;
   - and exactly one non-undef input, we can assume that all undefs are equal to this input.

Differential Revision: https://reviews.llvm.org/D104618
Reviewed By: lebedev.ri, nikic
The file was modifiedllvm/lib/Transforms/Scalar/LoopDeletion.cpp
The file was modifiedllvm/test/Transforms/LoopDeletion/eval_first_iteration.ll
Commit 5cb5225cf5c2adb55c55af842c4df5876e47169e by jim
[M68k] Refactor codegen patterns for logic operations and add tests for it

Refactor pat for and, or and xor operation and add missing tests for it

Reviewed By: myhsu

Differential Revision: https://reviews.llvm.org/D104626
The file was modifiedllvm/lib/Target/M68k/M68kInstrArithmetic.td
The file was addedllvm/test/CodeGen/M68k/Arith/bitwise.ll
Commit 0365af1a87ebc17a75dc6352e63cf1be536a49b4 by jim
[M68k] Add testcases for shift and rotate instructions

Add codegen testcases for lsl, lsr, asr, rol and ror instructions.

Reviewed By: myhsu

Differential Revision: https://reviews.llvm.org/D104685
The file was addedllvm/test/CodeGen/M68k/ShiftRotate/lsr.ll
The file was addedllvm/test/CodeGen/M68k/ShiftRotate/ror.ll
The file was addedllvm/test/CodeGen/M68k/ShiftRotate/asr.ll
The file was addedllvm/test/CodeGen/M68k/ShiftRotate/rol.ll
The file was addedllvm/test/CodeGen/M68k/ShiftRotate/lsl.ll
Commit dfafd56daa003c1cf0604afda308111f7fff2f04 by minyihh
[M68k] Fix incorrect #include-ed file in M68kSubtarget

In https://reviews.llvm.org/rG2193347e72fa , a cpp file is accidentally
included instead of its header file counterpart. This patch fixes this
error.
The file was modifiedllvm/lib/Target/M68k/M68kSubtarget.cpp