Skip to content

Add a compile feature to wasmtime-environ#8250

Merged
alexcrichton merged 5 commits intobytecodealliance:mainfrom
alexcrichton:wasmtime-env-no-compile
Mar 28, 2024
Merged

Add a compile feature to wasmtime-environ#8250
alexcrichton merged 5 commits intobytecodealliance:mainfrom
alexcrichton:wasmtime-env-no-compile

Conversation

@alexcrichton
Copy link
Member

This commit adds a compile-time feature to remove some dependencies of the wasmtime-environ crate. This compiles out support for compiling modules/components and makes the crate slimmer in terms of amount of code compiled along with its dependencies. Much of this should already have been statically removed by native linkers so this likely won't have any compile-size impact, but it's a nice-to-have in terms of organization.

This has a fair bit of shuffling around of code, but apart from renamings and movement there are no major changes here.

@alexcrichton alexcrichton requested a review from a team as a code owner March 28, 2024 01:05
@alexcrichton alexcrichton requested review from fitzgen and removed request for a team March 28, 2024 01:05
@github-actions github-actions bot added wasmtime:api Related to the API of the `wasmtime` crate itself wasmtime:config Issues related to the configuration of Wasmtime labels Mar 28, 2024
@github-actions
Copy link

Subscribe to Label Action

cc @peterhuene

Details This issue or pull request has been labeled: "wasmtime:api", "wasmtime:config"

Thus the following users have been cc'd because of the following labels:

  • peterhuene: wasmtime:api

To subscribe or unsubscribe from this label, edit the .github/subscribe-to-label.json configuration file.

Learn more.

@github-actions
Copy link

Label Messager: wasmtime:config

It looks like you are changing Wasmtime's configuration options. Make sure to
complete this check list:

  • If you added a new Config method, you wrote extensive documentation for
    it.

    Details

    Our documentation should be of the following form:

    Short, simple summary sentence.
    
    More details. These details can be multiple paragraphs. There should be
    information about not just the method, but its parameters and results as
    well.
    
    Is this method fallible? If so, when can it return an error?
    
    Can this method panic? If so, when does it panic?
    
    # Example
    
    Optional example here.
    
  • If you added a new Config method, or modified an existing one, you
    ensured that this configuration is exercised by the fuzz targets.

    Details

    For example, if you expose a new strategy for allocating the next instance
    slot inside the pooling allocator, you should ensure that at least one of our
    fuzz targets exercises that new strategy.

    Often, all that is required of you is to ensure that there is a knob for this
    configuration option in wasmtime_fuzzing::Config (or one
    of its nested structs).

    Rarely, this may require authoring a new fuzz target to specifically test this
    configuration. See our docs on fuzzing for more details.

  • If you are enabling a configuration option by default, make sure that it
    has been fuzzed for at least two weeks before turning it on by default.


Details

To modify this label's message, edit the .github/label-messager/wasmtime-config.md file.

To add new label messages or remove existing label messages, edit the
.github/label-messager.json configuration file.

Learn more.

Copy link
Member

@fitzgen fitzgen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't look closely at the actual code blocks, assuming it is all just code motion.

This commit adds a compile-time feature to remove some dependencies of
the `wasmtime-environ` crate. This compiles out support for compiling
modules/components and makes the crate slimmer in terms of amount of
code compiled along with its dependencies. Much of this should already
have been statically removed by native linkers so this likely won't have
any compile-size impact, but it's a nice-to-have in terms of
organization.

This has a fair bit of shuffling around of code, but apart from
renamings and movement there are no major changes here.
@alexcrichton alexcrichton force-pushed the wasmtime-env-no-compile branch from 887f2eb to 12888cc Compare March 28, 2024 14:56
@alexcrichton alexcrichton enabled auto-merge March 28, 2024 14:56
@alexcrichton alexcrichton added this pull request to the merge queue Mar 28, 2024
@alexcrichton alexcrichton removed this pull request from the merge queue due to a manual request Mar 28, 2024
@alexcrichton alexcrichton enabled auto-merge March 28, 2024 15:23
@alexcrichton alexcrichton added this pull request to the merge queue Mar 28, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Mar 28, 2024
@alexcrichton alexcrichton enabled auto-merge March 28, 2024 15:49
@alexcrichton alexcrichton added this pull request to the merge queue Mar 28, 2024
Merged via the queue into bytecodealliance:main with commit 1a7de7c Mar 28, 2024
@alexcrichton alexcrichton deleted the wasmtime-env-no-compile branch March 28, 2024 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

wasmtime:api Related to the API of the `wasmtime` crate itself wasmtime:config Issues related to the configuration of Wasmtime

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants