summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorMatt Arsenault <Matthew.Arsenault@amd.com>2019-02-04 23:41:59 +0000
committerMatt Arsenault <Matthew.Arsenault@amd.com>2019-02-04 23:41:59 +0000
commit24f14993e8743a4944756a8acc68d8c6fa7de9a6 (patch)
tree1277f0b9a843501ccc924e3e14b8507a079eea7c /llvm/lib
parent98b9f5b4b3863f8b4f206556ca167b808f46e420 (diff)
downloadbcm5719-llvm-24f14993e8743a4944756a8acc68d8c6fa7de9a6.tar.gz
bcm5719-llvm-24f14993e8743a4944756a8acc68d8c6fa7de9a6.zip
GlobalISel: Combine g_extract with g_merge_values
Try to use the underlying source registers. This enables legalization in more cases where some irregular operations are widened and others narrowed. This seems to make the test_combines_2 AArch64 test worse, since the MERGE_VALUES has multiple uses. Since this should be required for legalization, a hasOneUse check is probably inappropriate (or maybe should only be used if the merge is legal?). llvm-svn: 353121
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/CodeGen/GlobalISel/Legalizer.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/GlobalISel/Legalizer.cpp b/llvm/lib/CodeGen/GlobalISel/Legalizer.cpp
index b96827bd857..02fa4d12038 100644
--- a/llvm/lib/CodeGen/GlobalISel/Legalizer.cpp
+++ b/llvm/lib/CodeGen/GlobalISel/Legalizer.cpp
@@ -76,6 +76,7 @@ static bool isArtifact(const MachineInstr &MI) {
case TargetOpcode::G_UNMERGE_VALUES:
case TargetOpcode::G_CONCAT_VECTORS:
case TargetOpcode::G_BUILD_VECTOR:
+ case TargetOpcode::G_EXTRACT:
return true;
}
}
OpenPOWER on IntegriCloud