Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 75933 - [PATCH] emerge -s is slow with a lot of results
Summary: [PATCH] emerge -s is slow with a lot of results
Status: CONFIRMED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-12-28 11:45 UTC by Martin Ankerl
Modified: 2009-06-08 06:51 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
executes masked-check at a later time so that results are displayed sooner (emerge.patch,818 bytes, patch)
2004-12-28 11:48 UTC, Martin Ankerl
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Ankerl 2004-12-28 11:45:39 UTC
When using 'emerge -s' to search something that is found very frequently, it takes a very long time till all results are ready.

The problem is in class search, method execute. It takes a long time to find out the correct masked flag. This can be done at a later time, in output. The submitted patch fixes this.

Reproducible: Always
Steps to Reproduce:
1. Search for something that is frequently found, like 'emerge -s e'

Actual Results:  
emerge takes a very long time until results show up

Expected Results:  
same results, but the results should begin to show up as soon as possible
Comment 1 Martin Ankerl 2004-12-28 11:48:14 UTC
Created attachment 47044 [details, diff]
executes masked-check at a later time so that results are displayed sooner

move to /usr/bin to apply this patch
Comment 2 Alec Warner (RETIRED) archtester gentoo-dev Security 2004-12-28 11:52:38 UTC
If the total time is the same, does it really matter if the results are shown now or later?
Comment 3 Nicholas Jones (RETIRED) gentoo-dev 2004-12-28 11:55:08 UTC
Looking at the patch, there is something wrong.

It's appending the 'match' value onto that array... So you're storing
zero every time. I'm not certain that the moved 'match' is ever actually
used.
Comment 4 Martin Ankerl 2004-12-28 11:58:44 UTC
I think it does matter, from the usability point of view it is better to provide feedback as soon as possible, and not to wait.
Comment 5 Martin Ankerl 2004-12-28 12:04:42 UTC
Nicholas,

The only occurence of the search that I have found is in line nr. 2714, where searchinstance.execute(mysearch) is called, and afterwards searchinstance.output(). So there should not be anything different. 
But I forgot to mention this, this definitely is a hack, as it is not allowed to use the search results between execute() and output() as the masked flag is not set correctly
Comment 6 Jason Stubbs (RETIRED) gentoo-dev 2005-07-28 07:25:41 UTC
Putting a hold on feature requests for portage as they are drowning out the 
bugs. Most of these features should be available in the next major version of 
portage. But for the time being, they are just drowning out the major bugs and 
delaying the next version's progress. 
 
Any bugs that contain patches and any bugs for etc-update or dispatch-conf can 
be reopened. Sorry, I'm just not good enough with bugzilla. ;) 
Comment 7 Marius Mauch (RETIRED) gentoo-dev 2007-01-11 14:21:37 UTC
Reopening for consideration.