Skip to content

Commit 65144c8

Browse files
committed
Revert "[PPC] Give unaligned memory access lower cost on processor that supports it"
This reverts commit r292680. It is causing significantly worse performance and test timeouts in our internal builds. I have already routed reproduction instructions your way. llvm-svn: 293092
1 parent 840dee3 commit 65144c8

File tree

3 files changed

+1
-31
lines changed

3 files changed

+1
-31
lines changed

llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -401,10 +401,6 @@ int PPCTTIImpl::getMemoryOpCost(unsigned Opcode, Type *Src, unsigned Alignment,
401401
if (IsVSXType || (ST->hasVSX() && IsAltivecType))
402402
return Cost;
403403

404-
// Newer PPC supports unaligned memory access.
405-
if (TLI->allowsMisalignedMemoryAccesses(LT.second, 0))
406-
return Cost;
407-
408404
// PPC in general does not support unaligned loads and stores. They'll need
409405
// to be decomposed based on the alignment factor.
410406

llvm/test/Analysis/CostModel/PowerPC/load_store.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
; RUN: opt < %s -cost-model -analyze -mtriple=powerpc64-unknown-linux-gnu -mcpu=g5 -disable-ppc-unaligned | FileCheck %s
1+
; RUN: opt < %s -cost-model -analyze -mtriple=powerpc64-unknown-linux-gnu -mcpu=g5 | FileCheck %s
22
target datalayout = "E-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-f128:128:128-v128:128:128-n32:64"
33
target triple = "powerpc64-unknown-linux-gnu"
44

llvm/test/Analysis/CostModel/PowerPC/unaligned_ld_st.ll

Lines changed: 0 additions & 26 deletions
This file was deleted.

0 commit comments

Comments
 (0)