emscripten-core/emscripten

Add diagnose_if warnings for slow SIMD stuff?

オープン

#12,871 opened on 2020/11/24

 (3 件のコメント) (1 件のリアクション) (0 人の担当者)C++ (3,519 件のフォーク)batch import
good first bughelp wanted

Repository metrics

Stars
 (27,361 個のスター)
PR merge metrics
 (平均マージ 19d 10h) (30d で 147 merged PRs)

説明

The SIMD emulation occasionally drops to scalarized code. In addition to putting a bomb emoji in the doc, we can use something like __attribute__((diagnose_if(__EMSCRIPTEN_SIMD_🐌__ < 4, "💣", "warning")))__ to mark them in the header too. Clang would then emit warnings when a tagged function are called. Doing so might help developers with hunting down slow emulations.

Doc: https://clang.llvm.org/docs/AttributeReference.html#diagnose-if

コントリビューターガイド