From: David Chisnall Date: Fri, 30 Apr 2010 19:23:49 +0000 (+0000) Subject: Added a brief explanation of @llvm.global_{c,d}tors. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e31e9966ec7528736e5ee48e0ec32276a72c046c;p=oota-llvm.git Added a brief explanation of @llvm.global_{c,d}tors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102740 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/docs/LangRef.html b/docs/LangRef.html index aa6b797837c..b8a5fb23c50 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -2796,8 +2796,12 @@ should not be exposed to source languages.

- -

TODO: Describe this.

+
+%0 = type { i32, void ()* }
+@llvm.global_ctors = appending global [1 x %0] [%0 { i32 65535, void ()* @dtor }]
+
+

The @llvm.global_ctors array contains a list of constructor functions and associated priorities. The functions referenced by this array will be called in ascending order of priority (i.e. lowest first) when the module is loaded. The order of functions with the same priority is not defined. +

@@ -2807,8 +2811,13 @@ should not be exposed to source languages.

+
+%0 = type { i32, void ()* }
+@llvm.global_dtors = appending global [1 x %0] [%0 { i32 65535, void ()* @ctor }]
+
-

TODO: Describe this.

+

The @llvm.global_dtors array contains a list of destructor functions and associated priorities. The functions referenced by this array will be called in descending order of priority (i.e. highest first) when the module is loaded. The order of functions with the same priority is not defined. +