mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-19 17:37:24 +00:00
1ce9e00f8b
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49970 91177308-0d34-0410-b5e6-96231b3b80d8
14 lines
526 B
LLVM
14 lines
526 B
LLVM
; RUN: llvm-as < %s | llc
|
|
@global_long_1 = linkonce global i64 7 ; <i64*> [#uses=1]
|
|
@global_long_2 = linkonce global i64 49 ; <i64*> [#uses=1]
|
|
|
|
define i32 @main() {
|
|
%l1 = load i64* @global_long_1 ; <i64> [#uses=1]
|
|
%l2 = load i64* @global_long_2 ; <i64> [#uses=1]
|
|
%cond = icmp sle i64 %l1, %l2 ; <i1> [#uses=1]
|
|
%cast2 = zext i1 %cond to i32 ; <i32> [#uses=1]
|
|
%RV = sub i32 1, %cast2 ; <i32> [#uses=1]
|
|
ret i32 %RV
|
|
}
|
|
|