]> granicus.if.org Git - llvm/commit
[globalisel][tablegen] Map ld and st to G_LOAD and G_STORE. NFC
authorDaniel Sanders <daniel_l_sanders@apple.com>
Sun, 15 Oct 2017 02:41:12 +0000 (02:41 +0000)
committerDaniel Sanders <daniel_l_sanders@apple.com>
Sun, 15 Oct 2017 02:41:12 +0000 (02:41 +0000)
commit186cd4a1922c95e68eb4c4048142b0b30dcdcded
tree090cd4f7595a2997830d254c02cb7e5ca6c7775e
parent910074674e1aeb47211dfb4d69306ec27a143f77
[globalisel][tablegen] Map ld and st to G_LOAD and G_STORE. NFC

Summary:
There is an important mismatch between ISD::LOAD and G_LOAD (and likewise for
ISD::STORE and G_STORE). In SelectionDAG, ISD::LOAD is a non-atomic load
and atomic loads are handled by a separate node. However, this is not true of
GlobalISel's G_LOAD. For G_LOAD, the MachineMemOperand indicates the atomicity
of the operation. As a result, this mapping must also add a predicate that
checks for non-atomic MachineMemOperands.

This is NFC since these nodes always have predicates in practice and are
therefore always rejected at the moment.

Depends on D37443

Reviewers: ab, qcolombet, t.p.northover, rovka, aditya_nandakumar

Reviewed By: qcolombet

Subscribers: kristof.beyls, llvm-commits, igorb

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@315843 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/GlobalISel/InstructionSelector.h
include/llvm/CodeGen/GlobalISel/InstructionSelectorImpl.h
include/llvm/Target/GlobalISel/SelectionDAGCompat.td
utils/TableGen/GlobalISelEmitter.cpp