view llvm/test/ExecutionEngine/OrcLazy/global_aliases.ll @ 206:f17a3b42b08b

Added tag before-12 for changeset b7591485f4cd
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 07 Jun 2021 21:25:57 +0900
parents 1d019706d866
children 1f2b6ac9f198
line wrap: on
line source

; RUN: lli -jit-kind=orc-lazy %s
;
; Test handling of global aliases for function and variables.

@x = global i32 42, align 4
@y = alias i32, i32* @x

define i32 @foo() {
entry:
  %0 = load i32, i32* @y, align 4
  ret i32 %0
}

@bar = alias i32(), i32()* @foo

define i32 @main(i32 %argc, i8** %argv) {
entry:
  %0 = call i32() @bar()
  %1 = sub i32 %0, 42
  ret i32 %1
}