Phoenix
Object-oriented orthogonally persistent operating system
gcc.h
Go to the documentation of this file.
00001 /*
00002  * /phoenix/include/common/gcc.h
00003  *
00004  * This file is a part of Phoenix operating system.
00005  * Copyright (c) 2011-2012, Artyom Lebedev <artyom.lebedev@gmail.com>
00006  * All rights reserved.
00007  * See COPYING file for copyright details.
00008  */
00009 
00014 #ifndef GCC_H_
00015 #define GCC_H_
00016 
00017 #ifdef __cplusplus
00018 
00020 class Cxa {
00021 public:
00022     typedef void    (*CbkFunc)();
00023     struct CallbackList {
00024         u32     n;
00025         CbkFunc func[1];
00026     };
00027 
00028     static int ConstructStaticObjects();
00029     static int DestructStaticObjects();
00030 
00031 private:
00032     struct Destructor {
00033         void    (*func)(void *);
00034         void    *arg;
00035         void    *dso_handle;
00036     };
00037 };
00038 
00039 #endif /* __cplusplus */
00040 
00041 /* FIXME probably these functions not required for 64 bits platform */
00042 ASMCALL i64 __divdi3(i64 a, i64 b);
00043 ASMCALL u64 __udivdi3(u64 a, u64 b);
00044 ASMCALL i64 __moddi3(i64 a, i64 b);
00045 ASMCALL u64 __umoddi3(u64 a, u64 b);
00046 ASMCALL u64 __qdivrem(u64 u, u64 v, u64 *rem);
00047 
00048 #endif /* GCC_H_ */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines