aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/StackMaps.cpp
diff options
context:
space:
mode:
authorHal Finkel <hfinkel@anl.gov>2014-10-04 15:26:49 +0000
committerHal Finkel <hfinkel@anl.gov>2014-10-04 15:26:49 +0000
commit64567a80d20ec5489e988c176ead2efacac184ed (patch)
treeaeeac2571364e54934441f626734cd0ac0569354 /llvm/lib/CodeGen/StackMaps.cpp
parent936675e281dce21e45969ca0eff2a063ef430a37 (diff)
downloadllvm-64567a80d20ec5489e988c176ead2efacac184ed.zip
llvm-64567a80d20ec5489e988c176ead2efacac184ed.tar.gz
llvm-64567a80d20ec5489e988c176ead2efacac184ed.tar.bz2
Emit @llvm.assume for non-parameter lvalue align_value-attribute loads
We already add the align parameter attribute for function parameters that have the align_value attribute (or those with a typedef type having that attribute), which is an important special case, but does not handle pointers with value alignment assumptions that come into scope in any other way. To handle the general case, emit an @llvm.assume-based alignment assumption whenever we load the pointer-typed lvalue of an align_value-attributed variable (except for function parameters, which we already deal with at entry). I'll also note that this is more general than Intel's described support in: https://software.intel.com/en-us/articles/data-alignment-to-assist-vectorization which states that the compiler inserts __assume_aligned directives in response to align_value-attributed variables only for function parameters and for the initializers of local variables. I think that we can make the optimizer deal with this more-general scheme (which could lead to a lot of calls to @llvm.assume inside of loop bodies, for example), but if not, I'll rework this to be less aggressive. llvm-svn: 219052
Diffstat (limited to 'llvm/lib/CodeGen/StackMaps.cpp')
0 files changed, 0 insertions, 0 deletions