- Timestamp:
- Jul 16, 2005, 12:27:42 AM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gcc/gcc/config/i386/emx.c
-
Property cvs2svn:cvs-rev
changed from
1.31
to1.32
r2250 r2251 38 38 #endif 39 39 40 /** @todo remove debug code */41 40 /*#define BIRD_DEBUG - DO NOT COMMIT WITH THIS DEFINED!!! */ 42 41 … … 92 91 return psznone; 93 92 94 attr = (DECL_P (node) ? DECL_ATTRIBUTES (node) : TYPE_ATTRIBUTES (node));93 attr = DECL_P (node) ? DECL_ATTRIBUTES (node) : TYPE_P (node) ? TYPE_ATTRIBUTES (node) : NULL_TREE; 95 94 if (!attr) 96 95 return pszdefault; … … 640 639 if (TREE_CODE (TREE_TYPE (decl)) == METHOD_TYPE) 641 640 { 641 #if 0 642 642 /* Artificial methods are not affected by the import/export status of 643 643 their class unless they are virtual. */ 644 644 if (! DECL_ARTIFICIAL (decl) || DECL_VINDEX (decl)) 645 645 t = TREE_TYPE (TREE_VALUE (TYPE_ARG_TYPES (TREE_TYPE (decl)))); 646 #else /* from the CVS 3.4 branch. */ 647 /* Artificial methods are not affected by the import/export status 648 of their class unless they are COMDAT. Implicit copy ctor's and 649 dtor's are not affected by class status but virtual and 650 non-virtual thunks are. */ 651 if (!DECL_ARTIFICIAL (decl) || DECL_COMDAT (decl)) 652 t = TYPE_MAIN_VARIANT 653 (TREE_TYPE (TREE_VALUE (TYPE_ARG_TYPES (TREE_TYPE (decl))))); 654 dfprintf((stderr, "trace: associated_type: decl=%p t=%p\n", decl, t)); 655 DUMP(decl); 656 DUMP(t); 657 #endif 646 658 } 647 659 else if (DECL_CONTEXT (decl) … … 745 757 } 746 758 759 #if 0 747 760 /* Since we can't treat a pointer to a dllimport'd symbol as a 748 761 constant address, we turn off the attribute on C++ virtual … … 751 764 && (DECL_VIRTUAL_P (decl))) 752 765 return 0; 766 #else /* From the CVS 3.4 branch */ 767 /* Since we can't treat a pointer to a dllimport'd symbol as a 768 constant address, we turn off the attribute on C++ virtual 769 methods to allow creation of vtables using thunks. Don't mark 770 artificial methods either (in associated_type, only COMDAT 771 artificial method get import status from class context). */ 772 else if (TREE_CODE (TREE_TYPE (decl)) == METHOD_TYPE 773 && (DECL_VIRTUAL_P (decl) || DECL_ARTIFICIAL (decl))) 774 return 0; 775 #endif 753 776 754 777 return 1; … … 808 831 warning_with_decl (decl,"inconsistent dll linkage for '%s': dllexport assumed."); 809 832 /* Remove DLL_IMPORT_PREFIX. */ 810 oldname += 9;833 oldname += 3; /* not 9 since we're not doing the __imp_ bit. */ 811 834 DECL_NON_ADDR_CONST_P (decl) = 0; 812 835 } … … 834 857 { 835 858 const char *oldname; 836 char *newname;837 tree idp;838 rtx rtlname , newrtl;859 /*char *newname;*/ 860 /*tree idp;*/ 861 rtx rtlname/*, newrtl*/; 839 862 dfprintf ((stderr, "trace: i386_emx_mark_dllimport\n")); 840 863 … … 864 887 } 865 888 889 #if 0 /* we're only tagging along for the error handling but need no special handling. */ 866 890 newname = alloca (strlen (oldname) + 11); 867 891 sprintf (newname, "%ci.%s", DLL_IMPORT_EXPORT_PREFIX, oldname); … … 880 904 /* Can't treat a pointer to this as a constant address */ 881 905 DECL_NON_ADDR_CONST_P (decl) = 1; 906 #endif 882 907 } 883 908 … … 1095 1120 { 1096 1121 DUMP(decl); 1122 /* breaks thunks. Windows ain't doing this either. 1123 If it turns out to break stuff, try add "|| DECL_COMDAT (decl)". 1097 1124 if (!TREE_STATIC (decl)) 1098 1125 { … … 1100 1127 continue; 1101 1128 } 1129 */ 1102 1130 if (!q->asm_name) 1103 1131 q->asm_name = q->exported_name ? q->exported_name -
Property cvs2svn:cvs-rev
changed from
Note:
See TracChangeset
for help on using the changeset viewer.