Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / June 2004

Tip: Looking for answers? Try searching our database.

Data structure problem

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ubhay Kumar - 29 Jun 2004 15:44 GMT
Hi All...
I dont know whether this is the right place to post a datastructure problem
or not (if not please some one redirect)

I am using hashmaps in vc++. i have one particular use of the map for which
the performance is very slow.

Say i have 100 items in the map. The required operation is to update all the
keys in the map (KEYS and not the mapped data).
This operation is taking around 35 seconds for 300 such updates with .net
platform (which is actually very slow for my app).

Can somebody point me towards a better data structure or even the way hash
map/tables are implemented in .net.

Thanks in advance,
Ubhay.
Carl Daniel [VC++ MVP] - 29 Jun 2004 15:57 GMT
> Hi All...
>  I dont know whether this is the right place to post a datastructure
[quoted text clipped - 10 lines]
> Can somebody point me towards a better data structure or even the way
> hash map/tables are implemented in .net.

If you're getting bad performance from a hash map you probably have an
inappropriate hash function for your key set.

Note that updating keys in a map is accomplished only by erasing and
re-inserting the key/value pairs - there's no way to directly modify a key
value (since doing so would violate the invariants of the map).

If you can post some more information about how you're using the map,
someone can probably shed more light on the source of your performance woes.

-cd

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.