1*9880d681SAndroid Build Coastguard Worker; RUN: llc -verify-machineinstrs -relocation-model=pic %s -o - | FileCheck %s 2*9880d681SAndroid Build Coastguard Workertarget datalayout = "e-m:o-p:32:32-f64:32:64-f80:128-n8:16:32-S128" 3*9880d681SAndroid Build Coastguard Workertarget triple = "i386-apple-macosx" 4*9880d681SAndroid Build Coastguard Worker 5*9880d681SAndroid Build Coastguard Worker; Check that the register used as base pointer for setjmp 6*9880d681SAndroid Build Coastguard Worker; is properly initialized. 7*9880d681SAndroid Build Coastguard Worker; The test used to fail with the machine verifier complaining 8*9880d681SAndroid Build Coastguard Worker; that the global base pointer is not initialized. 9*9880d681SAndroid Build Coastguard Worker; PR26742. 10*9880d681SAndroid Build Coastguard Worker; 11*9880d681SAndroid Build Coastguard Worker; CHECK: test: 12*9880d681SAndroid Build Coastguard Worker; CHECK: calll [[BP_SETUP_LABEL:L[$0-9a-zA-Z_-]+]] 13*9880d681SAndroid Build Coastguard Worker; CHECK: [[BP_SETUP_LABEL]]: 14*9880d681SAndroid Build Coastguard Worker; CHECK-NEXT: popl [[BP:%[a-z]+]] 15*9880d681SAndroid Build Coastguard Worker; 16*9880d681SAndroid Build Coastguard Worker; CHECK: leal [[BLOCK_ADDR:LBB[$0-9a-zA-Z_-]+]]-[[BP_SETUP_LABEL]]([[BP]]), 17*9880d681SAndroid Build Coastguard Workerdefine i32 @test(i8* %tmp) { 18*9880d681SAndroid Build Coastguard Workerentry: 19*9880d681SAndroid Build Coastguard Worker %tmp9 = call i32 @llvm.eh.sjlj.setjmp(i8* %tmp) 20*9880d681SAndroid Build Coastguard Worker ret i32 %tmp9 21*9880d681SAndroid Build Coastguard Worker} 22*9880d681SAndroid Build Coastguard Worker 23*9880d681SAndroid Build Coastguard Workerdeclare i32 @llvm.eh.sjlj.setjmp(i8*) 24