[PATCH] D78062: Adding Comment Annotations to Outlined Functions

Andrew Litteken via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 13 21:42:44 PDT 2020


AndrewLitteken marked an inline comment as done.
AndrewLitteken added inline comments.


================
Comment at: llvm/test/CodeGen/AArch64/machine-outliner-function-annotate.ll:1
+; RUN: llc -verify-machineinstrs -enable-machine-outliner -mtriple=aarch64-linux-gnu < %s | FileCheck %s
+
----------------
paquette wrote:
> Is it possible to write this as a MIR test? In general, MIR tests are better for late passes like the outliner because they let us know exactly which instructions the outliner will work on. With IR tests, we are fragile against other changes in the code generator.
> 
> To generate MIR, you can run:
> 
> `llc (all the flags you want) -stop-before=machine-outliner -simplify-mir`
> 
> Then you can create a testcase with a `RUN` line similar to below:
> 
> `llc (all the flags you want) -run-pass=machine-outliner ...`
> 
I'm not sure that this works in this case, because the annotations are on the assembly code and don't show up in the MIR. Based on the docs I've found you can't output assembly from MIR.


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

https://reviews.llvm.org/D78062





More information about the llvm-commits mailing list