cpuinfo.pas 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. {
  2. $Id$
  3. Copyright (c) 1998-2002 by the Free Pascal development team
  4. Basic Processor information for the ARM
  5. See the file COPYING.FPC, included in this distribution,
  6. for details about the copyright.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  10. **********************************************************************}
  11. Unit CPUInfo;
  12. Interface
  13. uses
  14. globtype;
  15. Type
  16. bestreal = double;
  17. ts32real = single;
  18. ts64real = double;
  19. ts80real = type extended;
  20. ts128real = type extended;
  21. ts64comp = comp;
  22. pbestreal=^bestreal;
  23. { possible supported processors for this target }
  24. tprocessors =
  25. (no_processor,
  26. armv3,
  27. armv4,
  28. armv5
  29. );
  30. tfputype =
  31. (no_fpuprocessor,
  32. fpu_soft,
  33. fpu_libgcc,
  34. fpu_fpa,
  35. fpu_fpa10,
  36. fpu_fpa11,
  37. fpu_vfp
  38. );
  39. Const
  40. {# Size of native extended floating point type }
  41. extended_size = 8;
  42. {# Size of a multimedia register }
  43. mmreg_size = 16;
  44. { target cpu string (used by compiler options) }
  45. target_cpu_string = 'arm';
  46. { size of the buffer used for setjump/longjmp
  47. the size of this buffer is deduced from the
  48. jmp_buf structure in setjumph.inc file
  49. }
  50. { for linux: }
  51. jmp_buf_size = 220; { according to sizeof(jmp_buf) on my Zaurus (FK) }
  52. { calling conventions supported by the code generator }
  53. supported_calling_conventions : tproccalloptions = [
  54. pocall_internproc,
  55. pocall_compilerproc,
  56. pocall_inline,
  57. pocall_stdcall,
  58. { same as stdcall only different name mangling }
  59. pocall_cdecl,
  60. { same as stdcall only different name mangling }
  61. pocall_cppdecl,
  62. { same as stdcall but floating point numbers are handled like equal sized integers }
  63. pocall_softfloat
  64. ];
  65. processorsstr : array[tprocessors] of string[5] = ('',
  66. 'ARMV3',
  67. 'ARMV4',
  68. 'ARMV5'
  69. );
  70. fputypestr : array[tfputype] of string[6] = ('',
  71. 'SOFT',
  72. 'LIBGCC',
  73. 'FPA',
  74. 'FPA10',
  75. 'FPA11',
  76. 'VFP'
  77. );
  78. Implementation
  79. end.
  80. {
  81. $Log$
  82. Revision 1.8 2004-06-16 20:07:10 florian
  83. * dwarf branch merged
  84. Revision 1.7 2004/04/28 15:19:03 florian
  85. + syscall directive support for MorphOS added
  86. Revision 1.6.2.1 2004/05/01 16:02:10 peter
  87. * POINTER_SIZE replaced with sizeof(aint)
  88. * aint,aword,tconst*int moved to globtype
  89. Revision 1.6 2004/03/06 20:35:19 florian
  90. * fixed arm compilation
  91. * cleaned up code generation for exported linux procedures
  92. Revision 1.5 2003/12/01 18:43:32 peter
  93. * s128real type is not compatible with s80real
  94. Revision 1.4 2003/11/17 23:23:47 florian
  95. + first part of arm assembler reader
  96. Revision 1.3 2003/11/07 15:58:32 florian
  97. * Florian's culmutative nr. 1; contains:
  98. - invalid calling conventions for a certain cpu are rejected
  99. - arm softfloat calling conventions
  100. - -Sp for cpu dependend code generation
  101. - several arm fixes
  102. - remaining code for value open array paras on heap
  103. Revision 1.2 2003/08/25 23:20:38 florian
  104. + started to implement FPU support for the ARM
  105. * fixed a lot of other things
  106. Revision 1.1 2003/07/21 16:35:30 florian
  107. * very basic stuff for the arm
  108. }