[PATCH] D84569: [ELF] --reproduce should include lto sample profile

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 24 19:18:06 PDT 2020


MaskRay added inline comments.


================
Comment at: lld/ELF/Driver.cpp:506
 
   readConfigs(args);
 
----------------
Just move this line above so that we can use `config->ltoSampleProfile`


================
Comment at: lld/test/ELF/reproduce-lto.s:5
+# RUN: mkdir -p %t.dir/build1
+# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.dir/build1/foo.o
+# RUN: echo "# empty lto sample profile" > %t.dir/build1/empty_profile.txt
----------------
`-triple=x86_64`


================
Comment at: lld/test/ELF/reproduce-lto.s:6
+# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.dir/build1/foo.o
+# RUN: echo "# empty lto sample profile" > %t.dir/build1/empty_profile.txt
+# RUN: cd %t.dir
----------------
`echo > %t.dir/build1/empty_profile.txt`


================
Comment at: lld/test/ELF/reproduce-lto.s:8
+# RUN: cd %t.dir
+# RUN: ld.lld --hash-style=gnu build1/foo.o -o bar --reproduce repro1.tar --lto-sample-profile=%t.dir/build1/empty_profile.txt
+# RUN: tar tvf repro1.tar | FileCheck %s
----------------
Delete `--hash-style=gnu`

Use `-o /dev/null`


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D84569/new/

https://reviews.llvm.org/D84569





More information about the llvm-commits mailing list