619 // information, please see the libcollect man page. |
619 // information, please see the libcollect man page. |
620 |
620 |
621 // Method to let libcollector know about a dynamically loaded function. |
621 // Method to let libcollector know about a dynamically loaded function. |
622 // Because it is weakly bound, the calls become NOP's when the library |
622 // Because it is weakly bound, the calls become NOP's when the library |
623 // isn't present. |
623 // isn't present. |
|
624 #ifdef __APPLE__ |
|
625 // XXXDARWIN: Link errors occur even when __attribute__((weak_import)) |
|
626 // is added |
|
627 #define collector_func_load(x0,x1,x2,x3,x4,x5,x6) (0) |
|
628 #else |
624 void collector_func_load(char* name, |
629 void collector_func_load(char* name, |
625 void* null_argument_1, |
630 void* null_argument_1, |
626 void* null_argument_2, |
631 void* null_argument_2, |
627 void *vaddr, |
632 void *vaddr, |
628 int size, |
633 int size, |
629 int zero_argument, |
634 int zero_argument, |
630 void* null_argument_3); |
635 void* null_argument_3); |
631 #pragma weak collector_func_load |
636 #pragma weak collector_func_load |
632 #define collector_func_load(x0,x1,x2,x3,x4,x5,x6) \ |
637 #define collector_func_load(x0,x1,x2,x3,x4,x5,x6) \ |
633 ( collector_func_load ? collector_func_load(x0,x1,x2,x3,x4,x5,x6),0 : 0 ) |
638 ( collector_func_load ? collector_func_load(x0,x1,x2,x3,x4,x5,x6),0 : 0 ) |
|
639 #endif // __APPLE__ |
634 #endif // !_WINDOWS |
640 #endif // !_WINDOWS |
635 |
641 |
636 } // end extern "C" |
642 } // end extern "C" |
637 #endif // !IA64 |
643 #endif // !IA64 |
638 |
644 |