Page MenuHomePhabricator

[libc] add benchmarks for memcmp and bzero
ClosedPublic

Authored by gchatelet on Jun 18 2021, 2:09 AM.

Diff Detail

Event Timeline

gchatelet created this revision.Jun 18 2021, 2:09 AM
gchatelet requested review of this revision.Jun 18 2021, 2:09 AM
gchatelet updated this revision to Diff 352999.Jun 18 2021, 7:03 AM
  • Fix missing newline at EOF, uncomment no-builtin
courbet added inline comments.Jun 20 2021, 10:34 PM
libc/benchmarks/LibcMemoryBenchmarkMain.cpp
149

Can you please add a comment for why no memset for the casual reader ?

libc/src/string/CMakeLists.txt
305

?

gchatelet updated this revision to Diff 353935.Jun 23 2021, 5:30 AM
gchatelet marked an inline comment as done.
  • Remove unneeded no-builtin
  • Use memset instead of for-loop
gchatelet marked an inline comment as done.Jun 23 2021, 5:30 AM
gchatelet added inline comments.
libc/benchmarks/LibcMemoryBenchmarkMain.cpp
149

We can use memset actually (during benchmark the llvm-libc functions are only provided through the __llvm_libc namespace.

courbet accepted this revision.Jun 23 2021, 5:31 AM
This revision is now accepted and ready to land.Jun 23 2021, 5:31 AM
This revision was landed with ongoing or failed builds.Jun 23 2021, 7:20 AM
This revision was automatically updated to reflect the committed changes.