comparison gcc/fortran/trans-types.h @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children 1830386684a0
comparison
equal deleted inserted replaced
111:04ced10e8804 131:84e7813d76e9
1 /* Header for Fortran 95 types backend support. 1 /* Header for Fortran 95 types backend support.
2 Copyright (C) 2002-2017 Free Software Foundation, Inc. 2 Copyright (C) 2002-2018 Free Software Foundation, Inc.
3 Contributed by Paul Brook <paul@nowt.org> 3 Contributed by Paul Brook <paul@nowt.org>
4 and Steven Bosscher <s.bosscher@student.tudelft.nl> 4 and Steven Bosscher <s.bosscher@student.tudelft.nl>
5 5
6 This file is part of GCC. 6 This file is part of GCC.
7 7
21 21
22 22
23 #ifndef GFC_BACKEND_H 23 #ifndef GFC_BACKEND_H
24 #define GFC_BACKEND_H 24 #define GFC_BACKEND_H
25 25
26
26 extern GTY(()) tree gfc_array_index_type; 27 extern GTY(()) tree gfc_array_index_type;
27 extern GTY(()) tree gfc_array_range_type; 28 extern GTY(()) tree gfc_array_range_type;
28 extern GTY(()) tree gfc_character1_type_node; 29 extern GTY(()) tree gfc_character1_type_node;
29 extern GTY(()) tree ppvoid_type_node; 30 extern GTY(()) tree ppvoid_type_node;
30 extern GTY(()) tree pvoid_type_node; 31 extern GTY(()) tree pvoid_type_node;
31 extern GTY(()) tree prvoid_type_node; 32 extern GTY(()) tree prvoid_type_node;
32 extern GTY(()) tree pchar_type_node; 33 extern GTY(()) tree pchar_type_node;
33 extern GTY(()) tree gfc_float128_type_node; 34 extern GTY(()) tree gfc_float128_type_node;
34 extern GTY(()) tree gfc_complex_float128_type_node; 35 extern GTY(()) tree gfc_complex_float128_type_node;
35 36
37 /* logical_type_node is the Fortran LOGICAL type of default kind. In
38 addition to uses mandated by the Fortran standard, also prefer it
39 for compiler generated temporary variables, is it avoids some minor
40 issues with boolean_type_node (the C/C++ _Bool/bool). Namely:
41 - On x86, partial register stalls with 8/16 bit register access,
42 and length prefix changes.
43 - On s390 there is a compare with immediate and jump instruction,
44 but it works only with 32-bit quantities and not 8-bit such as
45 boolean_type_node.
46 */
47 extern GTY(()) tree logical_type_node;
48 extern GTY(()) tree logical_true_node;
49 extern GTY(()) tree logical_false_node;
50
36 /* This is the type used to hold the lengths of character variables. 51 /* This is the type used to hold the lengths of character variables.
37 It must be the same as the corresponding definition in gfortran.h. */ 52 It must be the same as the corresponding definition in gfortran.h. */
38 /* TODO: This is still hardcoded as kind=4 in some bits of the compiler
39 and runtime library. */
40 extern GTY(()) tree gfc_charlen_type_node; 53 extern GTY(()) tree gfc_charlen_type_node;
54
41 55
42 /* The following flags give us information on the correspondence of 56 /* The following flags give us information on the correspondence of
43 real (and complex) kinds with C floating-point types long double 57 real (and complex) kinds with C floating-point types long double
44 and __float128. */ 58 and __float128. */
45 extern bool gfc_real16_is_float128; 59 extern bool gfc_real16_is_float128;
57 /* trans-types.c */ 71 /* trans-types.c */
58 void gfc_init_kinds (void); 72 void gfc_init_kinds (void);
59 void gfc_init_types (void); 73 void gfc_init_types (void);
60 void gfc_init_c_interop_kinds (void); 74 void gfc_init_c_interop_kinds (void);
61 75
76 tree get_dtype_type_node (void);
62 tree gfc_get_int_type (int); 77 tree gfc_get_int_type (int);
63 tree gfc_get_real_type (int); 78 tree gfc_get_real_type (int);
64 tree gfc_get_complex_type (int); 79 tree gfc_get_complex_type (int);
65 tree gfc_get_logical_type (int); 80 tree gfc_get_logical_type (int);
66 tree gfc_get_char_type (int); 81 tree gfc_get_char_type (int);