pub fn new() -> Config {
        let mut flags = settings::builder();

        // There are two possible traps for division, and this way
        // we get the proper one if code traps.
        flags
            .enable("avoid_div_traps")
            .expect("should be valid flag");

        // Invert cranelift's default-on verification to instead default off.
        flags
            .set("enable_verifier", "false")
            .expect("should be valid flag");

        // Turn on cranelift speed optimizations by default
        flags
            .set("opt_level", "speed")
            .expect("should be valid flag");

        // We don't use probestack as a stack limit mechanism
        flags
            .set("enable_probestack", "false")
            .expect("should be valid flag");

        Config {
            tunables: Tunables::default(),
            flags,
            isa_flags: native::builder(),
            strategy: CompilationStrategy::Auto,
            #[cfg(feature = "cache")]
            cache_config: CacheConfig::new_cache_disabled(),
            profiler: Arc::new(NullProfilerAgent),
            memory_creator: None,
            max_wasm_stack: 1 << 20,
            features: WasmFeatures::default(),
        }
    }
/// Creates a new configuration object with the default configuration
/// specified.
Creates a new configuration object with the default configuration
specified.
Creates a new configuration object with the default configuration specified .
pub fn new() -> Config {
        let mut flags = settings::builder();
        // There are two possible traps for division, and this way
        // we get the proper one if code traps.
        flags
            .enable("avoid_div_traps")
            .expect("should be valid flag");
        // Invert cranelift's default-on verification to instead default off.
        flags
            .set("enable_verifier", "false")
            .expect("should be valid flag");
        // Turn on cranelift speed optimizations by default
        flags
            .set("opt_level", "speed")
            .expect("should be valid flag");
        // We don't use probestack as a stack limit mechanism
        flags
            .set("enable_probestack", "false")
            .expect("should be valid flag");
        Config {
            tunables: Tunables::default(),
            flags,
            isa_flags: native::builder(),
            strategy: CompilationStrategy::Auto,
            #[cfg(feature = "cache")]
            cache_config: CacheConfig::new_cache_disabled(),
            profiler: Arc::new(NullProfilerAgent),
            memory_creator: None,
            max_wasm_stack: 1 << 20,
            features: WasmFeatures::default(),
        }
    }
pub fn new ( ) -> Config { let mut flags = settings :: builder ( ) ; // There are two possible traps for division, and this way // we get the proper one if code traps. flags . enable ( " " ) . expect ( " " ) ; // Invert cranelift's default-on verification to instead default off. flags . set ( " " , " " ) . expect ( " " ) ; // Turn on cranelift speed optimizations by default flags . set ( " " , " " ) . expect ( " " ) ; // We don't use probestack as a stack limit mechanism flags . set ( " " , " " ) . expect ( " " ) ; Config { tunables : Tunables :: default ( ) , flags , isa_flags : native :: builder ( ) , strategy : CompilationStrategy :: Auto , # [ cfg ( feature " " ) ] cache_config : CacheConfig :: new_cache_disabled ( ) , profiler : Arc :: new ( NullProfilerAgent ) , memory_creator : None , max_wasm_stack : 1 << 20 , features : WasmFeatures :: default ( ) , } }
Creates a new configuration object with the default configuration
specified.
Creates a new configuration object with the default configuration specified .