Skip to content

Commit 69cb48c

Browse files
committed
Add RUN line for new interpreter and remove invalid test case
1 parent 5dd15ff commit 69cb48c

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

clang/test/CodeGenCXX/builtin-assume-dereferenceable-constexpr.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// RUN: %clang_cc1 -triple x86_64-unknown-unknown -std=c++14 -emit-llvm -o - %s | FileCheck %s
2+
// RUN: %clang_cc1 -triple x86_64-unknown-unknown -std=c++14 -emit-llvm -o - %s -fexperimental-new-constant-interpreter | FileCheck %s
23

34
int b = 10;
45
const int f = (__builtin_assume_dereferenceable((char*)&b + 1, 3), 12);
@@ -17,10 +18,6 @@ constexpr int fully_constexpr() {
1718
constexpr int i = fully_constexpr();
1819
int use_i = i;
1920

20-
void test_integral_ptr() {
21-
__builtin_assume_dereferenceable((int*)0x1234, 4);
22-
}
23-
2421
void test_nullptr() {
2522
__builtin_assume_dereferenceable(nullptr, 0);
2623
}
@@ -36,9 +33,6 @@ void test_function_ptr() {
3633

3734
// CHECK: @use_i = global i32 100
3835
//
39-
// CHECK: @{{_Z[0-9]+}}test_integral_ptrv
40-
// CHECK: call void @llvm.assume(i1 true) [ "dereferenceable"(ptr inttoptr (i64 4660 to ptr), i64 4) ]
41-
//
4236
// CHECK: @{{_Z[0-9]+}}test_nullptrv
4337
// CHECK: call void @llvm.assume(i1 true) [ "dereferenceable"(ptr null, i64 0) ]
4438
//

0 commit comments

Comments
 (0)