Code Monkey home page Code Monkey logo

Comments (7)

tbarbette avatar tbarbette commented on August 23, 2024 1

Well I'm happy to say this feature will be (partially) the subject of our upcoming ASPLOS'21 paper "PacketMill". Therefore closing it :) See https://github.com/aliireza/packetmill

from fastclick.

tbarbette avatar tbarbette commented on August 23, 2024

Maybe @cffs you have input to propose using C++ 14+ language facilities?
Again we could use source-to-source rewriting.

from fastclick.

cffs avatar cffs commented on August 23, 2024

If we manage to have a tool to propagate configuration parameters into the element code, and generate a number of element variants for different parameter sets, there is a risk of code size explosion, which might actually be detrimental to overall performance.
Maybe it should be restricted to a few important parameters which really affect the fastpath performance. Those could be chosen by the element developer (e.g. using the template approach outlined above), or by the configuration author (by adding a configuration keyword, something like FromDPDKDevice(STATIC true, ...), and then calling some click-propagate-params tool).

from fastclick.

tbarbette avatar tbarbette commented on August 23, 2024

Do you thing code size is really a problem? The unused code will not be accessed, it will sit in RAM, yes, but RAM is cheap and as long as it does not pollute the cache we do not really care.
High-speed equipments-wise. We should definitely keep a "small binary" option that deactivates the feature, as some people use Click in embedded devices.

from fastclick.

cffs avatar cffs commented on August 23, 2024

I was more thinking about instructions cache problems.
If the different variants are served by different cores (e.g. multiple FromDPDKDevice on different threads), this is not an issue, and specializing would likely be better.
However, you might also have many variants of an element on the same path and served by the same core. In this case, it may happen that instructions from one variant need to be trashed from cache to make room for instructions of another variant (depending on cache size and amount of code on the path). That can be costly if done for every batch of packets. In this case, a single element with one additional branch might give better performance if it can avoid caching issues.

from fastclick.

tbarbette avatar tbarbette commented on August 23, 2024

Ok we agree then. Let's allow specific designated parameters, and somehow warn the user to keep in mind not to use specialized versions too much. The template idea force the specialization though...

from fastclick.

aquatoney avatar aquatoney commented on August 23, 2024

a Big Congrats!

from fastclick.

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.