search for: functionimport

Displaying 20 results from an estimated 42 matches for "functionimport".

2016 Jul 22
2
[ThinLTO] Using two different IRMovers for the same composite module? (related to PR28180)
...same destination (or composite) module. During LTO, an IRMover is created in thinLTOBackendTask function(tools/gold/gold-plugin.cpp). linkInModule function, which is called by thinLTOBackendTask, calls the ‘move’ function of this IRMover. The other IRMover is created when “TheLinker” is created in FunctionImporter::importFunctions (lib/Transforms/IPO/FunctionImport.cpp). thinLTOBackendTask invokes FunctionImporeter::importFunctions as well, with a call chain of thinLTOBackendTask -->CodeGen::runAll (tools/gold/gold-plugin.cpp) --> CodeGen::runLTOPasses ((tools/gold/gold-plugin.cpp) --> FunctionImp...
2016 Jul 29
0
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...28, 2016 at 4:38 PM, Taewook Oh via llvm-dev < llvm-dev at lists.llvm.org> wrote: > Encountered “assert(GS != DefinedGlobals.end())” failure while running > ThinLTO. The assertion statement is in MustPreserveGV lambda function in > llvm::thinLTOInternalizeModule (lib/Transforms/IPO/FunctionImport.cpp). > > > > It seems that the assertion fails because it fails to recover the > "original name" of the global value. > ModuleSummaryIndex::getOriginalNameBeforePromote attempts to get the > original name by stripping .llvm.{HASH}, but what I observe is that ".1...
2016 Jul 28
2
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
Encountered “assert(GS != DefinedGlobals.end())” failure while running ThinLTO. The assertion statement is in MustPreserveGV lambda function in llvm::thinLTOInternalizeModule (lib/Transforms/IPO/FunctionImport.cpp). It seems that the assertion fails because it fails to recover the "original name" of the global value. ModuleSummaryIndex::getOriginalNameBeforePromote attempts to get the original name by stripping .llvm.{HASH}, but what I observe is that ".1" is still appended to the ex...
2016 Jul 29
0
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...From: *Teresa Johnson <tejohnson at google.com> > *Date: *Friday, July 29, 2016 at 3:30 PM > > *To: *Taewook Oh <twoh at fb.com> > *Cc: *via llvm-dev <llvm-dev at lists.llvm.org> > *Subject: *Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) > failed in FunctionImport.cpp > > > > > > > > On Fri, Jul 29, 2016 at 2:25 PM, Taewook Oh <twoh at fb.com> wrote: > > Hello Teresa, > > > > Thank you for your analysis. One thing to note is that the global > materializer materializes the value as a function declaration, not...
2016 Jul 29
0
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...From: *Teresa Johnson <tejohnson at google.com> > *Date: *Friday, July 29, 2016 at 7:05 AM > > *To: *Taewook Oh <twoh at fb.com> > *Cc: *via llvm-dev <llvm-dev at lists.llvm.org> > *Subject: *Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) > failed in FunctionImport.cpp > > > > > > > > On Thu, Jul 28, 2016 at 5:18 PM, Taewook Oh <twoh at fb.com> wrote: > > Hello Teresa, > > > > Thank you for your reply. I’m trying to create a small repro but find it > hard to nail down because originally it is a big build. Thi...
2016 Jul 29
2
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...e build artifacts :( Thanks, Taewook From: Teresa Johnson <tejohnson at google.com> Date: Friday, July 29, 2016 at 3:30 PM To: Taewook Oh <twoh at fb.com> Cc: via llvm-dev <llvm-dev at lists.llvm.org> Subject: Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp On Fri, Jul 29, 2016 at 2:25 PM, Taewook Oh <twoh at fb.com<mailto:twoh at fb.com>> wrote: Hello Teresa, Thank you for your analysis. One thing to note is that the global materializer materializes the value as a function declaration, not a function definition. As I pasted on...
2016 Aug 15
2
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...m: *Teresa Johnson <tejohnson at google.com> > *Date: *Tuesday, August 16, 2016 at 1:37 AM > > *To: *Taewook Oh <twoh at fb.com> > *Cc: *via llvm-dev <llvm-dev at lists.llvm.org> > *Subject: *Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) > failed in FunctionImport.cpp > > > > Hi Taewook, > > > > I had a better fix for this approved (D23015), but when I went to merge > this with the new LTO API I committed for pcc last week I discovered that > his new API already has the same effect. I will update the bug with this > info as w...
2016 Jul 30
1
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...From: *Teresa Johnson <tejohnson at google.com> > *Date: *Friday, July 29, 2016 at 3:52 PM > > *To: *Taewook Oh <twoh at fb.com> > *Cc: *via llvm-dev <llvm-dev at lists.llvm.org> > *Subject: *Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) > failed in FunctionImport.cpp > > > > > > > > On Fri, Jul 29, 2016 at 3:40 PM, Taewook Oh <twoh at fb.com> wrote: > > It was r274523. I’m not sure it was the same module. By mistake I > restarted the build with the previous version without backing backing up > the build artifacts :(...
2016 Jul 29
0
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...; *From: *Teresa Johnson <tejohnson at google.com> > *Date: *Thursday, July 28, 2016 at 5:08 PM > *To: *Taewook Oh <twoh at fb.com> > *Cc: *via llvm-dev <llvm-dev at lists.llvm.org> > *Subject: *Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) > failed in FunctionImport.cpp > > > > Hi Taewook, > > > > > > > > On Thu, Jul 28, 2016 at 4:38 PM, Taewook Oh via llvm-dev < > llvm-dev at lists.llvm.org> wrote: > > Encountered “assert(GS != DefinedGlobals.end())” failure while running > ThinLTO. The assertion statement...
2016 Jul 30
2
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...failure) comes back. Thanks, Taewook From: Teresa Johnson <tejohnson at google.com> Date: Friday, July 29, 2016 at 3:52 PM To: Taewook Oh <twoh at fb.com> Cc: via llvm-dev <llvm-dev at lists.llvm.org> Subject: Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp On Fri, Jul 29, 2016 at 3:40 PM, Taewook Oh <twoh at fb.com<mailto:twoh at fb.com>> wrote: It was r274523. I’m not sure it was the same module. By mistake I restarted the build with the previous version without backing backing up the build artifacts :( So a couple things were ad...
2016 Jul 29
3
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...with gold linker. Thanks, Taewook From: Teresa Johnson <tejohnson at google.com> Date: Thursday, July 28, 2016 at 5:08 PM To: Taewook Oh <twoh at fb.com> Cc: via llvm-dev <llvm-dev at lists.llvm.org> Subject: Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp Hi Taewook, On Thu, Jul 28, 2016 at 4:38 PM, Taewook Oh via llvm-dev <llvm-dev at lists.llvm.org<mailto:llvm-dev at lists.llvm.org>> wrote: Encountered “assert(GS != DefinedGlobals.end())” failure while running ThinLTO. The assertion statement is in MustPreserveGV lambda functi...
2016 Jul 29
2
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...es to fix the issue. Thanks, Taewook From: Teresa Johnson <tejohnson at google.com> Date: Friday, July 29, 2016 at 7:05 AM To: Taewook Oh <twoh at fb.com> Cc: via llvm-dev <llvm-dev at lists.llvm.org> Subject: Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp On Thu, Jul 28, 2016 at 5:18 PM, Taewook Oh <twoh at fb.com<mailto:twoh at fb.com>> wrote: Hello Teresa, Thank you for your reply. I’m trying to create a small repro but find it hard to nail down because originally it is a big build. This happens with gold linker. I think I...
2016 Apr 14
4
[ThinLTO] RFC: ThinLTO distributed backend interface
...Mehdi, let me know if this addresses your concerns. Peter, PTAL from the standpoint of any summary extensions needed for CFI and make sure they can fit into this model. Thanks, Teresa Background ---------------- Recent patch D18945/r266125 ([ThinLTO] Only compute imports for current module in FunctionImport pass) triggered a discussion (mostly over IRC) on how best to determine import/export decisions in distributed back end compiles. Import and export decisions are made by traversing the combined index. The actual importing happens in the FunctionImporter class, which is passed the set of values to...
2016 Aug 15
2
[ThinLTO] assert(GS != DefinedGlobals.end()) failed in FunctionImport.cpp
...m> >>> *Date: *Friday, July 29, 2016 at 3:52 PM >>> >>> *To: *Taewook Oh <twoh at fb.com> >>> *Cc: *via llvm-dev <llvm-dev at lists.llvm.org> >>> *Subject: *Re: [llvm-dev] [ThinLTO] assert(GS != DefinedGlobals.end()) >>> failed in FunctionImport.cpp >>> >>> >>> >>> >>> >>> >>> >>> On Fri, Jul 29, 2016 at 3:40 PM, Taewook Oh <twoh at fb.com> wrote: >>> >>> It was r274523. I’m not sure it was the same module. By mistake I >>> restarted th...
2018 May 09
0
lld + ThinLTO + fprofile-generate causes duplicate symbol errors
...:isWeakForLinker(OriginalLinkage)) + if (GlobalValue::isLocalLinkage(OriginalLinkage)) continue; // We need to emit only one of these. The prevailing module will keep it, // but turned into a weak, while the others will drop it when possible. diff --git a/llvm/lib/Transforms/IPO/FunctionImport.cpp b/llvm/lib/Transforms/IPO/FunctionImport.cpp index 246d75caefa2..61790c9fc435 100644 --- a/llvm/lib/Transforms/IPO/FunctionImport.cpp +++ b/llvm/lib/Transforms/IPO/FunctionImport.cpp @@ -765,7 +765,7 @@ void llvm::thinLTOResolveWeakForLinkerModule( return; } - if (!GlobalValue::...
2018 May 11
1
lld + ThinLTO + fprofile-generate causes duplicate symbol errors
...> + if (GlobalValue::isLocalLinkage(OriginalLinkage)) > continue; > // We need to emit only one of these. The prevailing module will keep > it, > // but turned into a weak, while the others will drop it when > possible. > diff --git a/llvm/lib/Transforms/IPO/FunctionImport.cpp > b/llvm/lib/Transforms/IPO/FunctionImport.cpp > index 246d75caefa2..61790c9fc435 100644 > --- a/llvm/lib/Transforms/IPO/FunctionImport.cpp > +++ b/llvm/lib/Transforms/IPO/FunctionImport.cpp > @@ -765,7 +765,7 @@ void llvm::thinLTOResolveWeakForLinkerModule( > return; &...
2016 Dec 23
0
ThinLTO promotion is ending up with "invalid" IR before IR-Linking
On Thu, Dec 22, 2016 at 8:55 PM, Mehdi Amini <mehdi.amini at apple.com> wrote: > Hey, > > As I’m playing with Metadata lazy-loading, I added a verifier right before > running the IRLinker in FunctionImport.cpp, and it does not pass (on > current trunk) in a few cases. One that I looked at ended up with aliases > pointing to available_externally functions for instance. > How do these look after IRLinking (in the dest module)? I looked at the logic in renameModuleForThinLTO and all the conver...
2016 Dec 23
6
ThinLTO promotion is ending up with "invalid" IR before IR-Linking
...ohnson at google.com> wrote: > > > > On Thu, Dec 22, 2016 at 8:55 PM, Mehdi Amini <mehdi.amini at apple.com <mailto:mehdi.amini at apple.com>> wrote: > Hey, > > As I’m playing with Metadata lazy-loading, I added a verifier right before running the IRLinker in FunctionImport.cpp, and it does not pass (on current trunk) in a few cases. One that I looked at ended up with aliases pointing to available_externally functions for instance. > > How do these look after IRLinking (in the dest module)? I looked at the logic in renameModuleForThinLTO and all the conversions...
2018 May 09
2
lld + ThinLTO + fprofile-generate causes duplicate symbol errors
Adding Peter to comment on the linker resolution issue. >From adding save-temps, it looks like lld and gold are giving different resolutions to the symbols, which is presumably creating this issue: (first file is with lld and second is with gold) $ diff a.out.resolution.txt gold/ 4c4 < -r=a.o,__llvm_profile_raw_version,plx --- > -r=a.o,__llvm_profile_raw_version,l 8,9c8,9 <
2016 Jul 22
3
[ThinLTO] Using two different IRMovers for the same composite module? (related to PR28180)
...stination module not empty. — Mehdi During LTO, an IRMover is created in thinLTOBackendTask function(tools/gold/gold-plugin.cpp). linkInModule function, which is called by thinLTOBackendTask, calls the ‘move’ function of this IRMover. The other IRMover is created when “TheLinker” is created in FunctionImporter::importFunctions (lib/Transforms/IPO/FunctionImport.cpp). thinLTOBackendTask invokes FunctionImporeter::importFunctions as well, with a call chain of thinLTOBackendTask -->CodeGen::runAll (tools/gold/gold-plugin.cpp) --> CodeGen::runLTOPasses ((tools/gold/gold-plugin.cpp)--> FunctionImpo...