[SLP] Add cost model for `llvm.powi.*` intrinsics
[llvm-project.git] / llvm / test / Transforms / InstSimplify / ConstProp / gep-alias.ll
blobb987f8b9ac9337b838fea5f680ed92522a3ea32c
1 ; RUN: opt -instcombine -S -o - %s | FileCheck %s\r
2 ; Test that we don't replace an alias with its aliasee when simplifying GEPs.\r
3 ; In this test case the transformation is invalid because it replaces the\r
4 ; reference to the symbol "b" (which refers to whichever instance of "b"\r
5 ; was chosen by the linker) with a reference to "a" (which refers to the\r
6 ; specific instance of "b" in this module).\r
7 \r
8 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"\r
9 target triple = "x86_64-unknown-linux-gnu"\r
11 @a = internal global [3 x ptr] zeroinitializer\r
12 @b = linkonce_odr alias [3 x ptr], ptr @a\r
14 define ptr @f() {\r
15   ; CHECK: ret ptr getelementptr ([3 x ptr], ptr @b, i64 0, i64 1)\r
16   ret ptr getelementptr ([3 x ptr], ptr @b, i64 0, i64 1)\r
17 }\r