Skip to content

Commit 99b2bf2

Browse files
committed
Adjust test/ConstantInt following rebase.
1 parent cbb9bb0 commit 99b2bf2

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

clang/lib/CodeGen/CGExprConstant.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2034,7 +2034,7 @@ ConstantLValueEmitter::tryEmitBase(const APValue::LValueBase &base) {
20342034
C = applyOffset(C);
20352035
C = CGM.getConstantSignedPointer(
20362036
C, AuthInfo.getKey(), nullptr,
2037-
cast_or_null<llvm::Constant>(AuthInfo.getDiscriminator()));
2037+
cast_or_null<llvm::ConstantInt>(AuthInfo.getDiscriminator()));
20382038
return ConstantLValue(C, /*applied offset*/ true);
20392039
}
20402040

clang/lib/CodeGen/CGPointerAuth.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ llvm::Constant *CodeGenModule::getFunctionPointer(llvm::Constant *Pointer,
6969
if (auto PointerAuth = getFunctionPointerAuthInfo(FunctionType))
7070
return getConstantSignedPointer(
7171
Pointer, PointerAuth.getKey(), /*StorageAddress=*/nullptr,
72-
cast_or_null<llvm::Constant>(PointerAuth.getDiscriminator()));
72+
cast_or_null<llvm::ConstantInt>(PointerAuth.getDiscriminator()));
7373

7474
return Pointer;
7575
}

clang/test/CodeGen/ptrauth-weak_import.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
extern void foo() __attribute__((weak_import));
55

66
// CHECK: define {{(dso_local )?}}void @bar()
7-
// CHECK: br i1 icmp ne (ptr ptrauth (ptr @foo, i32 0), ptr null), label
7+
// CHECK: [[TMP1:%.*]] = icmp ne ptr ptrauth (ptr @foo, i32 0), null
8+
// CHECK: br i1 [[TMP1]], label
89
void bar() {
910
if (foo)
1011
foo();

0 commit comments

Comments
 (0)