[PATCH] D35579: [SimplifyCFG] Generate lookup tables based on a function attribute
Chad Rosier via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 19 09:36:46 PDT 2017
mcrosier added a comment.
In https://reviews.llvm.org/D35579#814575, @sgundapa wrote:
> For backends with "tightly coupled memory", in scenarios where the data is far away from text pays a good amount of penalty in terms of latency.
> Hexagon is one such backend. The tables (both lookup and jump) which are being generated are treated as globals with internal linkage and by default
> will be placed in read only data.
>
> Interestingly when programmers specify the command line flag "-fno-jump-tables", they assume there is no data that goes in to other sections.
> In case of llvm, the attribute "no-jump-tables" has no effect on simplifyCFG which generates the lookup table. This leads me to introduce "no-lookup-tables"
It looks like TargetTransformInfo already has a hook, shouldBuildLookupTables(), for disabling this optimization. Why not just set that to false for Hexagon?
https://reviews.llvm.org/D35579
More information about the llvm-commits
mailing list