diff options
author | Anders Carlsson <andersca@mac.com> | 2010-02-05 18:38:45 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2010-02-05 18:38:45 +0000 |
commit | cb86e1088aea24aa658d90092d58be50221fe782 (patch) | |
tree | 0b9c75466976a5c2e85a32f19ce32b8c40b9acf5 /clang/test/CodeGenCXX/global-init.cpp | |
parent | 5a5473f0f8781e245ba52d51f225233766bbf756 (diff) | |
download | bcm5719-llvm-cb86e1088aea24aa658d90092d58be50221fe782.tar.gz bcm5719-llvm-cb86e1088aea24aa658d90092d58be50221fe782.zip |
Fix the bug that was breaking self-host, and re-land the static ctor fixes.
llvm-svn: 95400
Diffstat (limited to 'clang/test/CodeGenCXX/global-init.cpp')
-rw-r--r-- | clang/test/CodeGenCXX/global-init.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/test/CodeGenCXX/global-init.cpp b/clang/test/CodeGenCXX/global-init.cpp index fd8c1597556..b60e056d708 100644 --- a/clang/test/CodeGenCXX/global-init.cpp +++ b/clang/test/CodeGenCXX/global-init.cpp @@ -9,6 +9,8 @@ struct B { B(); ~B(); }; struct C { void *field; }; +struct D { ~D(); }; + // CHECK: @c = global %struct.C zeroinitializer, align 8 // CHECK: call void @_ZN1AC1Ev(%struct.A* @a) @@ -23,4 +25,7 @@ B b; // CHECK-NOT: call void @_ZN1CC1Ev(%struct.C* @c) C c; +// CHECK: call i32 @__cxa_atexit(void (i8*)* bitcast (void (%struct.A*)* @_ZN1DD1Ev to void (i8*)*), i8* getelementptr inbounds (%struct.A* @d, i32 0, i32 0), i8* bitcast (i8** @__dso_handle to i8*)) +D d; + // CHECK: define internal void @__cxx_global_initialization() { |