summaryrefslogtreecommitdiff
path: root/test/example/cpp-unit.cpp
diff options
context:
space:
mode:
authorAlon Zakai <azakai@google.com>2023-05-15 15:00:49 -0700
committerGitHub <noreply@github.com>2023-05-15 15:00:49 -0700
commit44cd751d9feda7c4b4b6c9d6af1e71541b90abac (patch)
treeb0a05fc26f027714ce0d45752ee44812768e0658 /test/example/cpp-unit.cpp
parent71a151240241fd50c42d88fe0ba9800c03527387 (diff)
downloadbinaryen-44cd751d9feda7c4b4b6c9d6af1e71541b90abac.tar.gz
binaryen-44cd751d9feda7c4b4b6c9d6af1e71541b90abac.tar.bz2
binaryen-44cd751d9feda7c4b4b6c9d6af1e71541b90abac.zip
[NFC] Optimize ArrayNew zero construction (#5722)
All array elements have the same type, so we can construct a single zero and just copy it. This makes ArrayNew of large arrays 2x faster. I also experimented with putting Literal::makeZero in a header, in hopes of inlining leading to licm helping here, but that did not help at all unfortunately, at least not in gcc.
Diffstat (limited to 'test/example/cpp-unit.cpp')
0 files changed, 0 insertions, 0 deletions