xref: /minix3/external/bsd/llvm/dist/clang/test/CodeGen/tbaa-thread-sanitizer.cpp (revision f4a2713ac843a11c696ec80c0a5e3e5d80b4d338)
1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 -triple x86_64-apple-darwin -emit-llvm -o - %s -fsanitize=thread -relaxed-aliasing -O1 | FileCheck %s
2*f4a2713aSLionel Sambuc 
3*f4a2713aSLionel Sambuc // Make sure we do not crash when relaxed-aliasing is on.
4*f4a2713aSLionel Sambuc // CHECK-NOT: !tbaa
5*f4a2713aSLionel Sambuc struct iterator { void *node; };
6*f4a2713aSLionel Sambuc 
7*f4a2713aSLionel Sambuc struct pair {
8*f4a2713aSLionel Sambuc   iterator first;
pairpair9*f4a2713aSLionel Sambuc   pair(const iterator &a) : first(a) {}
10*f4a2713aSLionel Sambuc };
11*f4a2713aSLionel Sambuc 
equal_range()12*f4a2713aSLionel Sambuc void equal_range() {
13*f4a2713aSLionel Sambuc   (void)pair(iterator());
14*f4a2713aSLionel Sambuc }
15