1; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mcpu=generic | FileCheck %s 2; 3; Verify that pass 'Constant Hoisting' is not run on optnone functions. 4; Without optnone, Pass 'Constant Hoisting' would firstly hoist 5; constant 0xBEEBEEBEC, and then rebase the other constant 6; (i.e. constant 0xBEEBEEBF4) with respect to the previous one. 7; With optnone, we check that constants are not coalesced. 8 9define i64 @constant_hoisting_optnone() #0 { 10; CHECK-LABEL: @constant_hoisting_optnone 11; CHECK-DAG: movabsq {{.*#+}} imm = 0xBEEBEEBF4 12; CHECK-DAG: movabsq {{.*#+}} imm = 0xBEEBEEBEC 13; CHECK: ret 14entry: 15 %0 = load i64, i64* inttoptr (i64 51250129900 to i64*) 16 %1 = load i64, i64* inttoptr (i64 51250129908 to i64*) 17 %2 = add i64 %0, %1 18 ret i64 %2 19} 20 21attributes #0 = { optnone noinline } 22