OSDN Git Service

[GlobalISel] Add a localizer pass for target to use
authorQuentin Colombet <qcolombet@apple.com>
Sat, 27 May 2017 01:34:00 +0000 (01:34 +0000)
committerQuentin Colombet <qcolombet@apple.com>
Sat, 27 May 2017 01:34:00 +0000 (01:34 +0000)
commita407cc079c5aa8b0b492eaac40c87f79c446750e
tree42ff187e52cb70f01ab2bda2d7d5b2f5e04daa11
parentc8237e4e744209d5ae4bd3b818edb68d1f4de195
[GlobalISel] Add a localizer pass for target to use

This reverts commit r299287 plus clean-ups.

The localizer pass is a helper pass that could be run at O0 in the GISel
pipeline to work around the deficiency of the fast register allocator.
It basically shortens the live-ranges of the constants so that the
allocator does not spill all over the place.

Long term fix would be to make the greedy allocator fast.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304051 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/GlobalISel/Localizer.h [new file with mode: 0644]
include/llvm/CodeGen/MachineRegisterInfo.h
include/llvm/InitializePasses.h
lib/CodeGen/GlobalISel/CMakeLists.txt
lib/CodeGen/GlobalISel/GlobalISel.cpp
lib/CodeGen/GlobalISel/Localizer.cpp [new file with mode: 0644]
test/CodeGen/AArch64/GlobalISel/localizer.mir [new file with mode: 0644]