[PATCH] D35577: Add -flookup-tables and -fno-lookup-tables flags

Krzysztof Parzyszek via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 24 08:10:58 PDT 2017


kparzysz added a comment.

In https://reviews.llvm.org/D35577#817944, @echristo wrote:

> "Should this just be part of the tuning for the hexagon backend and not options at all"


The ultimate decision as to what kind of code to generate out of a switch statement belongs to the customer.  The reasons to choose one way over another may involve factors that the compiler has no knowledge of (such as details of the target hardware).  I don't think we need separate options to control jump tables and lookup tables: one option to enable/disable the use of memory tables would be sufficient.


https://reviews.llvm.org/D35577





More information about the cfe-commits mailing list