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

Function small_memcmp_aligned_eq

cranelift/frontend/src/frontend.rs:1695–1721  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1693
1694 #[test]
1695 fn small_memcmp_aligned_eq() {
1696 let align_four = std::num::NonZeroU8::new(4).unwrap();
1697 small_memcmp_helper(
1698 "
1699block0:
1700 v6 = iconst.i64 0
1701 v1 -> v6
1702 v5 = iconst.i64 0
1703 v0 -> v5
1704 v2 = load.i32 aligned v0 ; v0 = 0
1705 v3 = load.i32 aligned v1 ; v1 = 0
1706 v4 = icmp eq v2, v3
1707 return v4",
1708 |builder, target, x, y| {
1709 builder.emit_small_memory_compare(
1710 target.frontend_config(),
1711 IntCC::Equal,
1712 x,
1713 y,
1714 4,
1715 align_four,
1716 align_four,
1717 MemFlagsData::new(),
1718 )
1719 },
1720 );
1721 }
1722
1723 #[test]
1724 fn small_memcmp_ipv6_ne() {

Callers

nothing calls this directly

Calls 5

small_memcmp_helperFunction · 0.85
frontend_configMethod · 0.80
newFunction · 0.50
unwrapMethod · 0.45

Tested by

no test coverage detected