[PATCH] D42375: Add --print-icf flag

George Rimar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 24 00:50:22 PST 2018


grimar added inline comments.


================
Comment at: test/ELF/print-icf.s:7
+# RUN: ld.lld %t %t1 -o %t2 --icf=all --no-print-icf-sections --print-icf-sections | FileCheck %s
+# RUN: ld.lld %t %t1 -o %t2 --icf=all --print-icf-sections --no-print-icf-sections | not FileCheck %s
+
----------------
I think it is better to use explicit way of checking the output:

# RUN: ld.lld %t %t1 -o %t2 --icf=all --print-icf-sections --no-print-icf-sections | FileCheck %s --check-prefix=PREFIX
# PREFIX-NOT: selected
# PREFIX-NOT: removing

Otherwise test can pass by mistake.


https://reviews.llvm.org/D42375





More information about the llvm-commits mailing list