[PATCH] D24638: [thinlto] Basic thinlto fdo heuristic

Mehdi AMINI via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 16 16:58:30 PDT 2016


mehdi_amini added inline comments.

================
Comment at: lib/Bitcode/Reader/BitcodeReader.cpp:6303
@@ +6302,3 @@
+        if (IsOldProfileFormat)
+          I += 2; // Skip 2 old fields (callsite_count, profile_count).
+        else if (HasProfile) // can interpret hotness with new version.
----------------
Prazek wrote:
> Prazek wrote:
> > Do you have some idea how this test should look like?
> > 
> > I was thinking about saving bc files from old version, and then reading them and see what happens.
> > Is there a way to just read bc file and then write it again? I could then compare the output with some existing test.
> > 
> > 
> I guess this would be good
> llvm-dis < %s.bc -o - | llvm-as | llvm-dis | FileCheck
> 
This does not read summaries.
Try `llvm-lto -thinlto-index-stats %s.bc`


https://reviews.llvm.org/D24638





More information about the llvm-commits mailing list