[llvm-dev] Is the correct behavior of getelementptr i192* for opt + llc -march=aarch64?

Mehdi Amini via llvm-dev llvm-dev at lists.llvm.org
Wed Nov 9 22:41:43 PST 2016


> On Nov 9, 2016, at 8:29 PM, MITSUNARI Shigeo via llvm-dev <llvm-dev at lists.llvm.org> wrote:
> 
> Hi Tom,
> 
>> Is your default target aarch64?  Otherwise opt may be assuming a different
>> target which might explain the difference.
> 
> No, My target is x86-64, x86, arm, aarch64, ..., then I'll avoid using i192* and datalayout.

There is nothing specific with i192. You will likely run into issues by not specifying the right datalayout.

The optimizations will always run with a datalayout: if you don’t specify one there will be a default one, which can cause problems on some target (like you saw on arm). 
For instance, the optimizer will assume a pointer size and optimize based on this.

— 
Mehdi


More information about the llvm-dev mailing list