[PATCH] D152891: [ADT] Add deduction guide for iterator_range
Balázs Benics via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Jun 17 04:26:01 PDT 2023
steakhal updated this revision to Diff 532384.
steakhal added a comment.
- Factor out ADl utilities
- Add SFINAE check for iterator_range constructor
I measured the clean build time before and after the patch on my Ubuntu 22.04.1 system.
I used `gcc (Ubuntu 11.3.0-1ubuntu1~22.04.1) 11.3.0` with the `mold` linker.
Baseline:
time cmake -S llvm -B build/rel-old -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra" -DCMAKE_BUILD_TYPE=Release
real 0m8.446s
user 0m6.587s
sys 0m1.691s
time ninja -C build/rel-old/
[5445/5445]
real 19m23.414s 1163.414s
user 431m9.467s
sys 18m20.037s
With this patch:
time cmake -S llvm -B build/rel-new -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra" -DCMAKE_BUILD_TYPE=Release
real 0m8.943s
user 0m6.956s
sys 0m1.818s
time ninja -C build/rel-new/
[5445/5445]
real 19m32.817s 1172.817s
user 433m30.939s
sys 18m20.295s
This means that we would have `0.808224759` % compile time regression with this patch. Is it acceptable?
(I only run the measurement once)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D152891/new/
https://reviews.llvm.org/D152891
Files:
llvm/include/llvm/ADT/ADL.h
llvm/include/llvm/ADT/STLExtras.h
llvm/include/llvm/ADT/iterator_range.h
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D152891.532384.patch
Type: text/x-patch
Size: 8839 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230617/fb904237/attachment.bin>
More information about the llvm-commits
mailing list