This is an archive of the discontinued LLVM Phabricator instance.

[SelectionDAG] Always preserve offset in MachinePointerInfo
ClosedPublic

Authored by efriedma on Apr 13 2020, 1:14 PM.

Details

Summary

Previously, getWithOffset() would drop the offset if the base was null. Because of this, MachineMemOperand would return the wrong result from getAlign() in these cases. MachineMemOperand stores the alignment of the pointer without the offset.

A bunch of MIR tests changed because we print the offset now.

Split off from D77687.

Diff Detail

Event Timeline

efriedma created this revision.Apr 13 2020, 1:14 PM
Herald added a project: Restricted Project. · View Herald TranscriptApr 13 2020, 1:14 PM
RKSimon accepted this revision.Apr 13 2020, 1:48 PM

LGTM with one minor, cheers.

llvm/include/llvm/CodeGen/MachineMemOperand.h
80

clang-format

This revision is now accepted and ready to land.Apr 13 2020, 1:48 PM
This revision was automatically updated to reflect the committed changes.