diff options
author | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-04-14 16:23:18 +0000 |
---|---|---|
committer | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-04-14 16:23:18 +0000 |
commit | ab2ba306f09948ff09fef49f3592d714c38b2d93 (patch) | |
tree | b12d13d305b3e049e0907c34ad5d505ce04fa415 /gcc/ada/s-osinte-kfreebsd-gnu.ads | |
parent | a39fe8c82fd895251538269b679047bd6fc98ac5 (diff) | |
download | gcc-ab2ba306f09948ff09fef49f3592d714c38b2d93.tar.gz |
2008-04-14 Basile Starynkevitch <basile@starynkevitch.net>
MELT branch merged with trunk r134275
stilly buggy for libgcc muldi3: internal compiler error: in
execute_ipa_pass_list, at passes.c:1235
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@134279 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/s-osinte-kfreebsd-gnu.ads')
-rw-r--r-- | gcc/ada/s-osinte-kfreebsd-gnu.ads | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/gcc/ada/s-osinte-kfreebsd-gnu.ads b/gcc/ada/s-osinte-kfreebsd-gnu.ads index 05fb928fbbb..17c11290500 100644 --- a/gcc/ada/s-osinte-kfreebsd-gnu.ads +++ b/gcc/ada/s-osinte-kfreebsd-gnu.ads @@ -223,7 +223,8 @@ package System.OS_Interface is function sysconf (name : int) return long; pragma Import (C, sysconf); - SC_CLK_TCK : constant := 2; + SC_CLK_TCK : constant := 2; + SC_NPROCESSORS_ONLN : constant := 84; ------------------------- -- Priority Scheduling -- @@ -255,6 +256,7 @@ package System.OS_Interface is type Thread_Body is access function (arg : System.Address) return System.Address; + pragma Convention (C, Thread_Body); function Thread_Body_Access is new Unchecked_Conversion (System.Address, Thread_Body); @@ -438,12 +440,31 @@ package System.OS_Interface is pragma Import (C, pthread_getspecific, "pthread_getspecific"); type destructor_pointer is access procedure (arg : System.Address); + pragma Convention (C, destructor_pointer); function pthread_key_create (key : access pthread_key_t; destructor : destructor_pointer) return int; pragma Import (C, pthread_key_create, "pthread_key_create"); + CPU_SETSIZE : constant := 1_024; + + type bit_field is array (1 .. CPU_SETSIZE) of Boolean; + for bit_field'Size use CPU_SETSIZE; + pragma Pack (bit_field); + pragma Convention (C, bit_field); + + type cpu_set_t is record + bits : bit_field; + end record; + pragma Convention (C, cpu_set_t); + + function pthread_setaffinity_np + (thread : pthread_t; + cpusetsize : size_t; + cpuset : access cpu_set_t) return int; + pragma Import (C, pthread_setaffinity_np, "__gnat_pthread_setaffinity_np"); + private type sigset_t is array (1 .. 4) of unsigned; |