選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

compiler.h 804B

123456789101112131415161718192021222324252627
  1. #ifndef _BITS_COMPILER_H
  2. #define _BITS_COMPILER_H
  3. FILE_LICENCE ( GPL2_OR_LATER );
  4. #ifndef ASSEMBLY
  5. /** Declare a function with standard calling conventions */
  6. #define __asmcall __attribute__ (( cdecl, regparm(0) ))
  7. /**
  8. * Declare a function with libgcc implicit linkage
  9. *
  10. * It seems as though gcc expects its implicit arithmetic functions to
  11. * be cdecl, even if -mrtd is specified. This is somewhat
  12. * inconsistent; for example, if -mregparm=3 is used then the implicit
  13. * functions do become regparm(3).
  14. *
  15. * The implicit calls to memcpy() and memset() which gcc can generate
  16. * do not seem to have this inconsistency; -mregparm and -mrtd affect
  17. * them in the same way as any other function.
  18. */
  19. #define __libgcc __attribute__ (( cdecl ))
  20. #endif /* ASSEMBLY */
  21. #endif /* _BITS_COMPILER_H */