Giter VIP home page Giter VIP logo

Comments (4)

dadhi avatar dadhi commented on August 17, 2024

@netcorefan1 Hi, could you share the Program.cs and csproj through the gist and not through the zip archive?

Also, I am not sure what is the MemoryOwner you are talking about - is it the ArrayPool wrapper?
Then how it can be used as a map?

from imtools.

netcorefan1 avatar netcorefan1 commented on August 17, 2024

@netcorefan1 Hi, could you share the Program.cs and csproj through the gist and not through the zip archive?

Many thanks for your support. Gist link

Also, I am not sure what is the MemoryOwner you are talking about - is it the ArrayPool wrapper?

Yes, it is the ArrayPool wrapper made by the community toolkit.

Then how it can be used as a map?

This is something that I really don't have any idea (I don't have the required low level knowledge). It is very uncommon, but someone seems to have done something similar with good results.
I have excluded such possibility from the beginning and rather I focused on trying to understand what between the two options could provide faster data access with less resources. There are also other operations which will probably work better with a map, but I'm at the beginning and so I can't do any estimation. So I decided to first focus on performance and check if I have done something wrong for getting so poor performance.

from imtools.

dadhi avatar dadhi commented on August 17, 2024

@netcorefan1

I have added the benchmark.

You are comparing different things here:

  • MemoryOwner.Span is the pre-allocated Array, ImHashMap is the Map/Dictionary
  • Moreover, ImHashMap is the immutable map (e.g. targeting the thread safety scenarios, non-locking, etc.), and making them faster and less memory consuming than the Immutable collections from the BCL.

Next version of ImTools will provide non thread safe map but faster and lighter, called SmallMap which beats the BCL Dictionary (but not the arrays).

from imtools.

dadhi avatar dadhi commented on August 17, 2024

closing

from imtools.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.