Giter Site home page Giter Site logo

Comments (10)

peter-lawrey avatar peter-lawrey commented on September 14, 2024

Can you give an indication of how much difference this would make to your
business? E.g. It would reduce the download times.
On 18/01/2015 3:12 PM, "Viktor Szathmáry" [email protected] wrote:

Many projects could benefit from drop-in replacement Set/Map
implementations (Object -> Object). Please provide a small distribution of
koloboke (in Maven central), that only contains this core, instead of the
20Mb version with all the primitive specializations


Reply to this email directly or view it on GitHub
#33.

from koloboke.

phraktle avatar phraktle commented on September 14, 2024

Hi Peter,

I imagine it would make more of a difference for Koloboke as more projects would use it ;) It simply hurts my sense of aesthetics that one would depend on a collections library an order of magnitude larger than the application itself, on the same order as the JDK runtime jar.

Kidding aside, in the cases where a memory-efficient primitive collection is a must have (i.e. the working set does not fit otherwise), one can justify pretty much any size of the distributable. In our use-case it's not a must-have but would provide around a 5% performance improvement, at the cost of tripling the distributable size and increasing deployment/restart times. A minimal edition would make the choice clear and would most likely expand the scope of applicability for Koloboke (e.g. even to mobile apps, though I understand that's not the original design context).

(Hopefully some day built-in specialization will make all this bloat unnecessary: http://cr.openjdk.java.net/~briangoetz/valhalla/specialization.html)

from koloboke.

peter-lawrey avatar peter-lawrey commented on September 14, 2024

You can configure a build which has exactly the combinations you need.

From our point of view we would have to have a good reason to distribute
all the combinations people might want.
On 18/01/2015 6:00 PM, "Viktor Szathmáry" [email protected] wrote:

Hi Peter,

I imagine it would make more of a difference for Koloboke as more projects
would use it ;) It simply hurts my sense of aesthetics that one would
depend on a collections library an order of magnitude larger than the
application itself, on the same order as the JDK runtime jar.

Kidding aside, in the cases where a memory-efficient primitive collection
is a must have (i.e. the working set does not fit otherwise), one can
justify pretty much any size of the distributable. In our use-case it's not
a must-have but would provide around a 5% performance improvement, at the
cost of tripling the distributable size and increasing deployment/restart
times. A minimal edition would make the choice clear and would most likely
expand the scope of applicability for Koloboke (e.g. even to mobile apps,
though I understand that's not the original design context).

(Hopefully some day built-in specialization will make all this bloat
unnecessary:
http://cr.openjdk.java.net/~briangoetz/valhalla/specialization.html)


Reply to this email directly or view it on GitHub
#33 (comment).

from koloboke.

fvalente avatar fvalente commented on September 14, 2024

Hello

I agree with Viktor; I used the library during testing for my application
and was about to include it as it brought about 10% improvement.
In the end, I decided adding close to 20 MB to my 4MB app was not worth the
performance improvement.
Personally, I only need drop in replacement for HashObjObjMaps.
I "might" consider creating a build later but i would rather have something
that does not require effort in figuring out and maintaining;

Thanks,
Fred

On Sun, Jan 18, 2015 at 7:00 PM, Viktor Szathmáry [email protected]
wrote:

Hi Peter,

I imagine it would make more of a difference for Koloboke as more projects
would use it ;) It simply hurts my sense of aesthetics that one would
depend on a collections library an order of magnitude larger than the
application itself, on the same order as the JDK runtime jar.

Kidding aside, in the cases where a memory-efficient primitive collection
is a must have (i.e. the working set does not fit otherwise), one can
justify pretty much any size of the distributable. In our use-case it's not
a must-have but would provide around a 5% performance improvement, at the
cost of tripling the distributable size and increasing deployment/restart
times. A minimal edition would make the choice clear and would most likely
expand the scope of applicability for Koloboke (e.g. even to mobile apps,
though I understand that's not the original design context).

(Hopefully some day built-in specialization will make all this bloat
unnecessary:
http://cr.openjdk.java.net/~briangoetz/valhalla/specialization.html)


Reply to this email directly or view it on GitHub
#33 (comment).

from koloboke.

phraktle avatar phraktle commented on September 14, 2024

Hi Peter,

The combination I had in mind is fairly universal: it's basically the equivalent of what's in the JDK already: HashObjObjMap and HashObjSet (and supporting classes), but none of the primitive specialization interfaces/implementations. Since people get by reasonably well with using the basic JDK collections too, I'm pretty sure that a minimal package would provide a good entry point for a lot of people to start using Koloboke collections. The upside for you is that the project might get more visibility/traction.

Regards,
Viktor

from koloboke.

leventov avatar leventov commented on September 14, 2024

I really don't know how to better resolve this problem. Is it Ok to ship identical classes in different packages? We can end up shipping 64 separate packages for all combinations, that is too much.

I know 20 Mb is unacceptably too much. Why you don't use ProGuard?

Also there was an idea to move code gen inside the lib and generate needed collections on the fly, ~ the same way as Java-Lang data model classes are generated & cached now.

from koloboke.

phraktle avatar phraktle commented on September 14, 2024

Hi @leventov,

I don't propose distributing all permutations either, just a basic JDK-equivalent core (objects only, no primitives). I agree, you do have to draw the line somewhere. I will let other users weigh in on whether this is as universally applicable as I think...

Thanks for the ProGuard tip, that might be applicable (though certainly not as convenient as a simple dependency). Runtime specialization might also be a good approach (in essence, that's what the Valhalla project is also considering).

It would also be helpful if you could expand on how to create such a basic distribution. I found https://github.com/OpenHFT/Koloboke/wiki/Koloboke:-roll-the-collection-implementation-with-features-you-need and https://github.com/OpenHFT/Koloboke/blob/master/lib/impl/build.gradle but it's not quite clear what the appropriate solution is.

Regards,
Viktor

from koloboke.

leventov avatar leventov commented on September 14, 2024

@phraktle to generate subset of impls refer to #26 (comment). For you it should be enough to insert never 'byte|char|short|int|long|float|double' line.

from koloboke.

sirinath avatar sirinath commented on September 14, 2024

On the fly generation would also be a since solution.

from koloboke.

leventov avatar leventov commented on September 14, 2024

This is effectively covered by Koloboke Compile.

from koloboke.

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.