Hi Quentin, After shrink-wrapping was enabled as default on AArch64, llc has a seg fault when compiling the attached .ll file on AArch64. My command is llc -mcpu=cortex-a57 bug.ll Best, Haicheng -------------- next part -------------- A non-text attachment was scrubbed... Name: bug.ll Type: application/octet-stream Size: 8983 bytes Desc: not available URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20151120/9fb7aa5b/attachment.obj>
Arnaud A. de Grandmaison via llvm-dev
2015-Nov-20 14:31 UTC
[llvm-dev] [AArch64] bug in shrink-wrapping
+CC llvm-dev> -----Original Message----- > From: Arnaud A. de Grandmaison [mailto:arnaud.degrandmaison at arm.com] > Sent: 20 November 2015 15:28 > To: 'qcolombet at apple.com' > Cc: 'haicheng at codeaurora.org' > Subject: RE: [llvm-dev] [AArch64] bug in shrink-wrapping > > Now with memory leak addressed. > > Cheers, > Arnaud > > > -----Original Message----- > > From: Arnaud A. de Grandmaison > [mailto:arnaud.degrandmaison at arm.com] > > Sent: 20 November 2015 14:42 > > To: 'qcolombet at apple.com' > > Cc: 'haicheng at codeaurora.org' > > Subject: RE: [llvm-dev] [AArch64] bug in shrink-wrapping > > > > There is a memory leak in my previous patch, let me fix it. > > > > Cheers, > > Arnaud > > > > > -----Original Message----- > > > From: Arnaud A. de Grandmaison > > [mailto:arnaud.degrandmaison at arm.com] > > > Sent: 20 November 2015 12:49 > > > To: qcolombet at apple.com > > > Cc: 'haicheng at codeaurora.org' > > > Subject: RE: [llvm-dev] [AArch64] bug in shrink-wrapping > > > > > > Hi Quentin, > > > > > > I believe the attached patch fixes the issue. Can you review it ? > > > > > > Cheers, > > > Arnaud > > > > > > > -----Original Message----- > > > > From: llvm-dev [mailto:llvm-dev-bounces at lists.llvm.org] On Behalf > > > > Of via llvm-dev > > > > Sent: 20 November 2015 05:37 > > > > To: qcolombet at apple.com > > > > Cc: llvm-dev at lists.llvm.org > > > > Subject: [llvm-dev] [AArch64] bug in shrink-wrapping > > > > > > > > Hi Quentin, > > > > > > > > After shrink-wrapping was enabled as default on AArch64, llc has a > > > > seg fault when compiling the attached .ll file on AArch64. > > > > > > > > My command is > > > > > > > > llc -mcpu=cortex-a57 bug.ll > > > > > > > > Best, > > > > > > > > Haicheng-------------- next part -------------- A non-text attachment was scrubbed... Name: 0001-ShrinkWrap-Teach-ShrinkWrap-to-handle-targets-requir.patch Type: application/octet-stream Size: 10392 bytes Desc: not available URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20151120/c4b02288/attachment.obj>
Quentin Colombet via llvm-dev
2015-Nov-20 17:07 UTC
[llvm-dev] [AArch64] bug in shrink-wrapping
Hi Arnaud, Thanks for following up with that and sorry for the breakage. Couple of comments: MachineLoopInfo *MLI; + RegScavenger *RS; Would it make sense to use a unique_ptr here? That should eliminate the need of having explicit deletes. +; RUN: llc -mtriple=aarch64-linux-gnu -o - %s Add -enable-shrink-wrap=true and a second RUN line with -enable-shrink-wrap=false. Then add check lines for both to ensure shrink-wrapping is doing the right thing. + %0 = load i32, i32* @g1, align 4 Please use opt -instnamer to get rid of the numbered variables. Those are a pain when updating the tests :). Other than that LGTM! Cheers, -Quentin> On Nov 20, 2015, at 6:31 AM, Arnaud A. de Grandmaison <arnaud.degrandmaison at arm.com> wrote: > > +CC llvm-dev > >> -----Original Message----- >> From: Arnaud A. de Grandmaison [mailto:arnaud.degrandmaison at arm.com] >> Sent: 20 November 2015 15:28 >> To: 'qcolombet at apple.com' >> Cc: 'haicheng at codeaurora.org' >> Subject: RE: [llvm-dev] [AArch64] bug in shrink-wrapping >> >> Now with memory leak addressed. >> >> Cheers, >> Arnaud >> >>> -----Original Message----- >>> From: Arnaud A. de Grandmaison >> [mailto:arnaud.degrandmaison at arm.com] >>> Sent: 20 November 2015 14:42 >>> To: 'qcolombet at apple.com' >>> Cc: 'haicheng at codeaurora.org' >>> Subject: RE: [llvm-dev] [AArch64] bug in shrink-wrapping >>> >>> There is a memory leak in my previous patch, let me fix it. >>> >>> Cheers, >>> Arnaud >>> >>>> -----Original Message----- >>>> From: Arnaud A. de Grandmaison >>> [mailto:arnaud.degrandmaison at arm.com] >>>> Sent: 20 November 2015 12:49 >>>> To: qcolombet at apple.com >>>> Cc: 'haicheng at codeaurora.org' >>>> Subject: RE: [llvm-dev] [AArch64] bug in shrink-wrapping >>>> >>>> Hi Quentin, >>>> >>>> I believe the attached patch fixes the issue. Can you review it ? >>>> >>>> Cheers, >>>> Arnaud >>>> >>>>> -----Original Message----- >>>>> From: llvm-dev [mailto:llvm-dev-bounces at lists.llvm.org] On Behalf >>>>> Of via llvm-dev >>>>> Sent: 20 November 2015 05:37 >>>>> To: qcolombet at apple.com >>>>> Cc: llvm-dev at lists.llvm.org >>>>> Subject: [llvm-dev] [AArch64] bug in shrink-wrapping >>>>> >>>>> Hi Quentin, >>>>> >>>>> After shrink-wrapping was enabled as default on AArch64, llc has a >>>>> seg fault when compiling the attached .ll file on AArch64. >>>>> >>>>> My command is >>>>> >>>>> llc -mcpu=cortex-a57 bug.ll >>>>> >>>>> Best, >>>>> >>>>> Haicheng > <0001-ShrinkWrap-Teach-ShrinkWrap-to-handle-targets-requir.patch>