HomePhabricator

Copy utilities updated and added for MI flags

Description

Copy utilities updated and added for MI flags

Summary: This patch adds a GlobalIsel copy utility into MI for flags and updates the instruction emitter for the SDAG path. Some tests show new behavior and I added one for GlobalIsel which mirrors an SDAG test for handling nsw/nuw.

Reviewers: spatel, wristow, arsenm

Reviewed By: arsenm

Subscribers: wdng

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

Details

Committed
mcberg2017Sep 19 2018, 11:52 AM
Reviewer
arsenm
Differential Revision
D52006: Copy utilities updated and added for MI flags
Parents
rL342575: [x86] change names of vector splitting helper functions; NFC
Branches
Unknown
Tags
Unknown

Event Timeline

It seems that following test is broken with this change: DebugInfo/WebAssembly/dbg-value-live-interval.ll
Confirmed that reverting the change locally fixes the tests. Could you please take a look.

Ok, looking into it now.

The fixed test for WebAssembly is in rL342598.

Thanks for the fix!

bjope added a subscriber: bjope.Sep 19 2018, 4:08 PM
bjope added inline comments.
/llvm/trunk/include/llvm/CodeGen/MachineInstr.h
1529

This method is not copying the flags. It is more like an OR operation (otherwise it would clear the flags if they weren't set in the input instruction).

And it is quite confusing (hard to understand) what "all flags" means, as it only touches some MI flags.

So if further changes will be done regarding this for other reasons, you might as well consider to find a better name and description for this method.