From ddfa1a6c18afd4cfe78778e7f29145801b6d8fbe Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Wed, 9 Mar 2016 04:17:36 +0000 Subject: [WebAssembly] Update comments about irreducible control flow. llvm-svn: 262995 --- llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp') diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp b/llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp index be77222f873..1a7716a5d94 100644 --- a/llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp +++ b/llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp @@ -13,6 +13,10 @@ /// loops; they appear as CFG cycles that are not recorded in MachineLoopInfo /// due to being unnatural. /// +/// Note that LLVM has a generic pass that lowers irreducible control flow, but +/// it linearizes control flow, turning diamonds into two triangles, which is +/// both unnecessary and undesirable for WebAssembly. +/// /// TODO: The transformation implemented here handles all irreducible control /// flow, without exponential code-size expansion, though it does so by creating /// inefficient code in many cases. Ideally, we should add other -- cgit v1.2.3