Skip to content

Avoid calling C functions wrapping intgemm if intrinsic isn't native #66

Open
@kpu

Description

@kpu

I'm letting browsermt/bergamot-translator#265 in because it's a net improvement. But for the use case where Firefox isn't providing native multiplication, it will be slower due to bouncing WASM to JS to WASM every call. Instead the C++ should just not call the C functions and use the C++ interface to intgemm directly.

This requires sensing the presence of the native support at runtime. Options are JS tells us (in configuration) or C++ senses it by e.g. having incorrect implementations of the C functions internally / setting a global variable from the implementation that tells it to use the internal implementation (C++ on top of webassembly).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions