GithubHelp home page GithubHelp logo

Comments (8)

Ivan-Velickovic avatar Ivan-Velickovic commented on August 15, 2024

setvar_vaddr is optional, so is the only problematic variable microkit_name?

from microkit.

Ivan-Velickovic avatar Ivan-Velickovic commented on August 15, 2024

Having an option such as --no-elf-patching to the tool may be possible, but I would only want to do this if this is a problem across multiple/all systems programming languages.

Changing Microkit to work around a limitation in Rust seems weird.

from microkit.

nspin avatar nspin commented on August 15, 2024

This Rust scenario is just the specific reason why I've found myself wishing the tool had this slightly more general behavior.

I see the change I'm proposing as a slight generalization of the current behavior. From:

Patch each variable

To:

Patch each variable that actually exists in the binary

Making the tool more permissive in this way would simplify PD constructions by reducing the assumptions made about their structure.

from microkit.

Ivan-Velickovic avatar Ivan-Velickovic commented on August 15, 2024

But it seems there is only one assumption we are talking about here, and that is the existence of microkit_name, right?

from microkit.

Ivan-Velickovic avatar Ivan-Velickovic commented on August 15, 2024

I would find the behaviour of the tool weird if you had in your system description setvar_vaddr and then it didn't actually do that because of some control flow that is hidden from the user.

from microkit.

nspin avatar nspin commented on August 15, 2024

The tool derives, from the system description, a set of variables that it would patch for each PD. The assumption that I'm talking about is the assumption that all of these variables are present in the corresponding PD binaries.

from microkit.

nspin avatar nspin commented on August 15, 2024

I would find the behaviour of the tool weird if you had in your system description setvar_vaddr and then it didn't actually do that because of some control flow that is hidden from the user.

A case where I think that behavior would be nice is during development, before a PD developer has built out the PD to the point where the relevant variable is actually used.

from microkit.

Ivan-Velickovic avatar Ivan-Velickovic commented on August 15, 2024

A case where I think that behavior would be nice is during development, before a PD developer has built out the PD to the point where the relevant variable is actually used.

Then during development just omit setvar_vaddr?

The behaviour of the variable patching is I think very clear right now. You ask the tool to patch a variable, and it does it. If it can't patch the variable you get a clear error message.

This approach would remove that clear behaviour, and I am not convinced right now that it is beneficial to do that just because a compiler invalidates the assumption. It seems that you are working around the behaviour of a compiler. I do not think it is unreasonable for a compiler for a systems programming language to explicitly leave in a symbol at the request of its user.

I will continue thinking about the issue, I haven't reached a conclusion.

from microkit.

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.