MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / verify

Method verify

cranelift/codegen/src/context.rs:252–261  ·  view source on GitHub ↗

Run the verifier on the function. Also check that the dominator tree and control flow graph are consistent with the function. TODO: rename to "CLIF validate" or similar.

(&self, fisa: FOI)

Source from the content-addressed store, hash-verified

250 ///
251 /// TODO: rename to "CLIF validate" or similar.
252 pub fn verify<'a, FOI: Into<FlagsOrIsa<'a>>>(&self, fisa: FOI) -> VerifierResult<()> {
253 let mut errors = VerifierErrors::default();
254 let _ = verify_context(&self.func, &self.cfg, &self.domtree, fisa, &mut errors);
255
256 if errors.is_empty() {
257 Ok(())
258 } else {
259 Err(errors)
260 }
261 }
262
263 /// Run the verifier only if the `enable_verifier` setting is true.
264 pub fn verify_if<'a, FOI: Into<FlagsOrIsa<'a>>>(&self, fisa: FOI) -> CodegenResult<()> {

Callers 1

verify_ifMethod · 0.45

Calls 3

verify_contextFunction · 0.85
OkFunction · 0.85
is_emptyMethod · 0.45

Tested by

no test coverage detected