From e4d220e8c93e875842f328459f8d1c9bb8043303 Mon Sep 17 00:00:00 2001 From: Hans Wennborg Date: Wed, 25 Nov 2015 00:05:13 +0000 Subject: [PATCH] Revert r253528: "[X86] Enable shrink-wrapping by default." This caused PR25607 and also caused Chromium to crash on start-up. (Also had to update test/CodeGen/X86/avx-splat.ll, which was committed after shrink wrapping was enabled.) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254044 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/X86/X86FrameLowering.h | 5 ----- test/CodeGen/X86/avx-splat.ll | 10 +++++----- test/CodeGen/X86/tail-opts.ll | 2 +- 3 files changed, 6 insertions(+), 11 deletions(-) diff --git a/lib/Target/X86/X86FrameLowering.h b/lib/Target/X86/X86FrameLowering.h index d90a3935b3f..68dc8edfd43 100644 --- a/lib/Target/X86/X86FrameLowering.h +++ b/lib/Target/X86/X86FrameLowering.h @@ -143,11 +143,6 @@ public: MachineBasicBlock::iterator I, uint64_t Amount) const; - /// Returns true if the target will correctly handle shrink wrapping. - bool enableShrinkWrapping(const MachineFunction &MF) const override { - return true; - } - /// Wraps up getting a CFI index and building a MachineInstr for it. void BuildCFI(MachineBasicBlock &MBB, MachineBasicBlock::iterator MBBI, DebugLoc DL, MCCFIInstruction CFIInst) const; diff --git a/test/CodeGen/X86/avx-splat.ll b/test/CodeGen/X86/avx-splat.ll index dadeaaf6c05..2fdea2eb256 100644 --- a/test/CodeGen/X86/avx-splat.ll +++ b/test/CodeGen/X86/avx-splat.ll @@ -57,19 +57,19 @@ entry: define <8 x float> @funcE() nounwind { ; CHECK-LABEL: funcE: ; CHECK: ## BB#0: ## %for_exit499 +; CHECK-NEXT: pushq %rbp +; CHECK-NEXT: movq %rsp, %rbp +; CHECK-NEXT: andq $-32, %rsp +; CHECK-NEXT: subq $1312, %rsp ## imm = 0x520 ; CHECK-NEXT: xorl %eax, %eax ; CHECK-NEXT: ## implicit-def: %YMM0 ; CHECK-NEXT: testb %al, %al ; CHECK-NEXT: jne LBB4_2 ; CHECK-NEXT: ## BB#1: ## %load.i1247 -; CHECK-NEXT: pushq %rbp -; CHECK-NEXT: movq %rsp, %rbp -; CHECK-NEXT: andq $-32, %rsp -; CHECK-NEXT: subq $1312, %rsp ## imm = 0x520 ; CHECK-NEXT: vbroadcastss {{[0-9]+}}(%rsp), %ymm0 +; CHECK-NEXT: LBB4_2: ## %__load_and_broadcast_32.exit1249 ; CHECK-NEXT: movq %rbp, %rsp ; CHECK-NEXT: popq %rbp -; CHECK-NEXT: LBB4_2: ## %__load_and_broadcast_32.exit1249 ; CHECK-NEXT: retq allocas: %udx495 = alloca [18 x [18 x float]], align 32 diff --git a/test/CodeGen/X86/tail-opts.ll b/test/CodeGen/X86/tail-opts.ll index bf778e5bad2..c522ba60d6b 100644 --- a/test/CodeGen/X86/tail-opts.ll +++ b/test/CodeGen/X86/tail-opts.ll @@ -277,8 +277,8 @@ declare fastcc %union.tree_node* @default_conversion(%union.tree_node*) nounwind ; CHECK-LABEL: foo: ; CHECK: callq func -; CHECK-NEXT: popq ; CHECK-NEXT: .LBB4_2: +; CHECK-NEXT: popq ; CHECK-NEXT: ret define void @foo(i1* %V) nounwind { -- 2.34.1