1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=x86_64-linux-gnu -global-isel -verify-machineinstrs < %s -o - | FileCheck %s
4 define i8 @const_i8() {
5 ; CHECK-LABEL: const_i8:
7 ; CHECK-NEXT: movb $2, %al
12 define i16 @const_i16() {
13 ; CHECK-LABEL: const_i16:
15 ; CHECK-NEXT: movw $3, %ax
20 define i32 @const_i32() {
21 ; CHECK-LABEL: const_i32:
23 ; CHECK-NEXT: movl $4, %eax
28 define i64 @const_i64() {
29 ; CHECK-LABEL: const_i64:
31 ; CHECK-NEXT: movabsq $68719476720, %rax # imm = 0xFFFFFFFF0
36 ;i64 value fit into u32
37 define i64 @const_i64_u32() {
38 ; CHECK-LABEL: const_i64_u32:
40 ; CHECK-NEXT: movl $1879048192, %eax # imm = 0x70000000
45 ;i64 value fit into i32
46 define i64 @const_i64_i32() {
47 ; CHECK-LABEL: const_i64_i32:
49 ; CHECK-NEXT: movq $-1, %rax
54 define void @main(ptr %data) {
57 ; CHECK-NEXT: movq $0, %rax
58 ; CHECK-NEXT: movq %rax, (%rdi)
60 store ptr null, ptr %data, align 8