1 2010-04-09 Eric Botcazou <ebotcazou@adacore.com>
3 * gcc-interface/gigi.h (gnat_mark_addressable): Rename parameter.
4 * gcc-interface/decl.c (maybe_variable): Do not set TREE_STATIC on _REF
5 node. Use the type of the operand to set TREE_READONLY.
6 * gcc-interface/trans.c (Identifier_to_gnu): Do not set TREE_STATIC on
7 _REF node. Do not overwrite TREE_READONLY.
8 (call_to_gnu): Rename local variable and fix various nits. In the
9 copy-in/copy-out case, build the SAVE_EXPR manually.
10 (convert_with_check): Call protect_multiple_eval in lieu of save_expr
11 and fold the computations.
12 (protect_multiple_eval): Always save entire fat pointers.
13 (maybe_stabilize_reference): Minor tweaks.
14 (gnat_stabilize_reference_1): Likewise. Do not deal with tcc_constant,
15 tcc_type and tcc_statement.
16 * gcc-interface/utils.c (convert_to_fat_pointer): Call
17 protect_multiple_eval in lieu of save_expr.
18 (convert): Minor tweaks.
19 (maybe_unconstrained_array): Do not set TREE_STATIC on _REF node.
20 (builtin_type_for_size): Call gnat_type_for_size directly.
21 * gcc-interface/utils2.c (contains_save_expr_p): Delete.
22 (contains_null_expr): Likewise
23 (gnat_build_constructor): Do not call it.
24 (compare_arrays): Deal with all side-effects, use protect_multiple_eval
25 instead of gnat_stabilize_reference to protect the operands.
26 (nonbinary_modular_operation): Call protect_multiple_eval in lieu of
28 (maybe_wrap_malloc): Likewise.
29 (build_allocator): Likewise.
30 (build_unary_op) <INDIRECT_REF>: Do not set TREE_STATIC on _REF node.
31 (gnat_mark_addressable): Rename parameter.
33 2010-04-08 Eric Botcazou <ebotcazou@adacore.com>
35 * gcc-interface/ada-tree.h (TYPE_RETURNS_UNCONSTRAINED_P): Rename into.
36 (TYPE_RETURN_UNCONSTRAINED_P): ...this.
37 (TYPE_RETURNS_BY_REF_P): Rename into.
38 (TYPE_RETURN_BY_DIRECT_REF_P): ...this.
39 (TYPE_RETURNS_BY_TARGET_PTR_P): Delete.
40 * gcc-interface/gigi.h (create_subprog_type): Adjust parameter names.
41 (build_return_expr): Likewise.
42 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Subprogram_Type>:
43 Rename local variables. If the return Mechanism is By_Reference, pass
44 return_by_invisible_ref_p to create_subprog_type instead of toggling
45 TREE_ADDRESSABLE. Test return_by_invisible_ref_p in order to annotate
46 the mechanism. Use regular return for contrained types with non-static
47 size and return by invisible reference for unconstrained return types
48 with default discriminants. Update comment.
49 * gcc-interface/trans.c (Subprogram_Body_to_gnu): If the function
50 returns by invisible reference, turn the RESULT_DECL into a pointer.
51 Do not handle DECL_BY_REF_P in the CICO case here.
52 (call_to_gnu): Remove code handling return by target pointer. For a
53 function call, if the return type has non-constant size, generate the
54 assignment with an INIT_EXPR.
55 (gnat_to_gnu) <N_Return_Statement>: Remove dead code in the CICO case.
56 If the function returns by invisible reference, build the copy return
58 (add_decl_expr): Initialize the variable with an INIT_EXPR.
59 * gcc-interface/utils.c (create_subprog_type): Adjust parameter names.
60 Adjust for renaming of macros. Copy the node only when necessary.
61 (create_subprog_decl): Do not toggle TREE_ADDRESSABLE on the return
62 type, only change DECL_BY_REFERENCE on the RETURN_DECL.
63 (convert_from_reference): Delete.
64 (is_byref_result): Likewise.
65 (gnat_genericize_r): Likewise.
66 (gnat_genericize): Likewise.
67 (end_subprog_body): Do not call gnat_genericize.
68 * gcc-interface/utils2.c (build_binary_op) <INIT_EXPR>: New case.
69 (build_return_expr): Adjust parameter names, logic and comment.
71 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
73 * exp_pakd.adb (Create_Packed_Array_Type): Always use a modular type
74 if the size is small enough. Propagate the alignment if there is an
75 alignment clause on the original array type.
76 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Modular_Integer_Subtype>
77 Deal with under-aligned packed array types. Copy the size onto the
78 justified modular type and don't lay it out again. Likewise for the
79 padding type built for other under-aligned subtypes.
80 * gcc-interface/utils.c (finish_record_type): Do not set a default mode
83 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
85 * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Procedure>: Set default
86 alignment on the RETURN type built for the Copy-In Copy-Out mechanism.
88 2010-04-07 Eric Botcazou <ebotcazou@adacore.com>
90 * gcc-interface/trans.c (call_to_gnu): In the return-by-target-ptr case
91 do not set the result type if there is a specified target and do not
92 convert the result in any cases.
93 (protect_multiple_eval): Make direct SAVE_EXPR for CALL_EXPR.
94 (maybe_stabilize_reference) <COMPOUND_EXPR>: Merge with CALL_EXPR.
96 2010-03-10 Eric Botcazou <ebotcazou@adacore.com>
98 * gcc-interface/Makefile.in (SPARC/Solaris): Use sparcv8plus.
100 2010-02-27 Eric Botcazou <ebotcazou@adacore.com>
103 * gcc-interface/utils2.c (build_binary_op) <EQ_EXPR>: Assert that fat
104 pointer base types are variant of each other. Apply special treatment
105 for null to fat pointer types in all cases.
107 2010-01-28 Pascal Obry <obry@adacore.com>
109 * s-win32.ads: Add some missing constants.
111 2010-01-28 Vincent Celier <celier@adacore.com>
113 * prj-attr-pm.adb (Add_Attribute): Do nothing if To_Package is
116 2010-01-28 Robert Dewar <dewar@adacore.com>
118 * gnat_rm.texi: Minor correction
120 2010-01-27 Pascal Obry <obry@adacore.com>
122 * g-awk.adb: ensure that an AWK session is reusable.
124 2010-01-27 Vasiliy Fofanov <fofanov@adacore.com>
126 * g-regist.adb (For_Every_Key): Fix previous change.
129 2010-01-27 Thomas Quinot <quinot@adacore.com>
131 * lib-writ.ads: Current version of spec for new N (note) ALI lines
133 2010-01-27 Yannick Moy <moy@adacore.com>
135 * a-cdlili.adb (Insert): Correct exception message when cursor
136 designates wrong list.
138 2010-01-27 Vincent Celier <celier@adacore.com>
140 * gnatcmd.adb: When there is only one main specified, the package
141 support Switches (<main>) and attribute Switches is specified for the
142 main, use these switches, instead of Default_Switches ("Ada").
144 2010-01-27 Robert Dewar <dewar@adacore.com>
146 * sem_prag.adb, par-prag.adb, snames.ads-tmpl: pragma Dimension initial
148 * exp_disp.adb: Minor reformatting
150 2010-01-27 Tristan Gingold <gingold@adacore.com>
152 * seh_init.c: Use __ImageBase instead of _ImageBase.
154 2010-01-27 Javier Miranda <miranda@adacore.com>
156 * exp_disp.ads, exp_disp.adb (Expand_Interface_Thunk): Modify the
157 profile of interface thunks. The type of the controlling formal is now
158 the covered interface type (instead of the target tagged type).
160 2010-01-27 Sergey Rybin <rybin@adacore.com>
162 * gnat_rm.texi, gnat_ugn.texi: Update gnatcheck doc.
164 2010-01-27 Robert Dewar <dewar@adacore.com>
166 * sinput.ads, sinput.adb (Sloc_Range): Applies to all nodes, formal
167 changed from Expr to N.
169 2010-01-26 Thomas Quinot <quinot@adacore.com>
171 * gnat_ugn.texi: Adjust documentation of -gnatz switches.
172 * usage.adb: Replace line for -gnatz with two lines for -gnatzc and
175 2010-01-26 Vincent Celier <celier@adacore.com>
177 * prj-attr.adb: Add new attribute Library_Install_Name_Option
178 Replace attribute Run_Path_Origin_Supported with Run_Path_Origin
179 * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process
180 attributes Run_Path_Option and Library_Install_Name_Option.
181 * prj.ads (Project_Configuration): Replace component
182 Run_Path_Origin_Supported with component Run_Path_Origin. Add new
183 component Library_Install_Name_Option.
184 * snames.ads-tmpl: Add new standard name Library_Install_Name_Option
185 Replace Run_Path_Origin_Supported with Run_Path_Origin
187 2010-01-26 Ed Schonberg <schonberg@adacore.com>
189 * sem_ch8.adb (Use_One_Package): Within an instance, an actual package
190 is not hidden by a homograph declared in another actual package.
192 2010-01-26 Robert Dewar <dewar@adacore.com>
194 * par_sco.adb (Traverse_Declarations_Or_Statements): Only generate
195 decisions for pragmas Assert, Check, Precondition, Postcondition if
197 * scos.ads: Update comments.
198 * get_scos.adb, put_scos.adb: Minor fix to code reading statement SCOs.
199 Also remove obsolete code for CT (exit point) SCOs.
201 2010-01-26 Thomas Quinot <quinot@adacore.com>
203 * switch-c.adb: Fix handling of -gnatz*
205 2010-01-26 Robert Dewar <dewar@adacore.com>
207 * par_sco.adb (Traverse_Declarations_Or_Statements): Separate F/W
208 qualifiers for FOR/WHILE loops
209 * scos.ads: Use separate type letters F/W for for/while loops
211 2010-01-26 Robert Dewar <dewar@adacore.com>
213 * get_scos.adb (Get_SCOs): Implement new form of CS entries (multiple
214 entries per line, one for each statement in the sequence).
215 * par_sco.adb (Traverse_Declarations_Or_Statements): Increase array
216 size from 100 to 10_000 for SC_Array to avoid any real possibility of
217 overflow. Output decisions in for loops.
218 Exclude labels from CS lines.
219 * scos.ads: Clarify that label is not included in the entry point
221 2010-01-26 Robert Dewar <dewar@adacore.com>
223 * par_sco.adb (Traverse_Declarations_Or_Statments): Implement new
224 format of statement sequence SCO entries (one location/statement).
225 * put_scos.adb (Put_SCOs): Implement new format of CS lines
226 * scos.ads: Update comments.
227 * sem_eval.adb: Minor reformatting.
229 2010-01-26 Robert Dewar <dewar@adacore.com>
231 * par_sco.ads, par_sco.adb (Set_Statement_Entry): New handling of exits
232 (Extend_Statement_Sequence): New procedures
233 (Traverse_Declarations_Or_Statements): New handling for exits.
235 2010-01-26 Robert Dewar <dewar@adacore.com>
237 * par_sco.adb (Traverse_Declarations_Or_Statements): Add processing for
240 2010-01-26 Robert Dewar <dewar@adacore.com>
242 * par_sco.adb (Is_Logical_Operator): Exclude AND/OR/XOR
243 * scos.ads: Clarify handling of logical operators
245 2010-01-26 Arnaud Charlet <charlet@adacore.com>
247 * s-tpoben.adb: Update comments.
249 2010-01-26 Robert Dewar <dewar@adacore.com>
251 * freeze.adb (Set_Small_Size): Don't set size if alignment clause
254 2010-01-26 Robert Dewar <dewar@adacore.com>
256 * scos.ads: Clean up documentation, remove obsolete XOR references
257 2010-01-26 Vincent Celier <celier@adacore.com>
259 * gnat_ugn.texi: Complete documentation on the restrictions for
260 combined options in -gnatxxx switches.
263 2010-01-26 Arnaud Charlet <charlet@adacore.com>
265 * s-tpoben.adb (Initialize_Protection_Entries): If a PO is created from
266 a controlled operation, abort is already deferred at this point, so we
267 need to use Defer_Abort_Nestable.
269 2010-01-26 Vincent Celier <celier@adacore.com>
271 * prj-conf.adb (Get_Config_Switches): Check for a default language for
272 a project extending a project with no languages.
274 2010-01-26 Vincent Celier <celier@adacore.com>
276 * switch-c.adb (Scan_Front_End_Switches): Take into account options
278 Allow -gnateG to be followed by other options.
280 2010-01-26 Robert Dewar <dewar@adacore.com>
282 * s-commun.ads, s-osprim-mingw.adb, s-stchop-vxworks.adb, sem_aggr.adb,
283 s-vxwext.adb, sem_ch10.adb, sem_eval.adb, sem_prag.adb: Minor
286 2010-01-26 Vasiliy Fofanov <fofanov@adacore.com>
288 * g-regist.adb, g-regist.ads (For_Every_Key): New generic procedure
289 that allows to iterate over all subkeys of a key.
291 2010-01-26 Ed Falis <falis@adacore.com>
293 * sysdep.c: enable NFS for VxWorks MILS
294 * env.c: enable __gnat_environ for VxWorks MILS
295 * gcc-interface/Makefile.in: Add VxWorks MILS target pairs.
297 2010-01-25 Bob Duff <duff@adacore.com>
299 * sem_aggr.adb (Resolve_Array_Aggregate): Check for the case where this
300 is an internally-generated positional aggregate, and the bounds are
301 already correctly set. We don't want to overwrite those bounds with
302 bounds determined by context.
304 2010-01-25 Robert Dewar <dewar@adacore.com>
306 * g-sercom.ads, gnatcmd.adb, gnatlink.adb, a-ststio.adb, exp_ch6.adb,
307 exp_ch9.adb, g-sechas.ads: Minor reformatting.
309 2010-01-25 Thomas Quinot <quinot@adacore.com>
311 * s-commun.adb (Last_Index): Count must be converted to SEO (a signed
312 integer type) before subtracting 1, otherwise the computation may wrap
313 (because size_t is modular) and cause the conversion to fail.
315 2010-01-25 Ed Falis <falis@adacore.com>
317 * sysdep.c, init.c: Adapt to support full run-time on VxWorks MILS.
319 2010-01-25 Vincent Celier <celier@adacore.com>
321 * prj-attr.adb: New attribute Run_Path_Origin_Required
322 * prj-nmsc.adb (Process_Project_Level_Simple_Attributes): Process new
323 attribute Run_Path_Origin_Required.
324 * prj.ads (Project_Configuration): New component
325 Run_Path_Origin_Supported.
326 * snames.ads-tmpl: New standard name Run_Path_Origin_Required
328 2010-01-25 Ed Schonberg <schonberg@adacore.com>
330 * sem_aggr.adb (Resolve_Array_Aggregate): If the bounds in a choice
331 have errors, do not continue resolution of the aggregate.
332 * sem_eval.adb (Eval_Indexed_Component): Do not attempt to evaluate if
333 the array type indicates an error.
335 2010-01-25 Bob Duff <duff@adacore.com>
337 * sinfo.ads: Minor comment fixes.
339 2010-01-25 Bob Duff <duff@adacore.com>
341 * exp_ch4.adb, exp_aggr.adb: Minor comment fixes and code clean up.
343 2010-01-25 Arnaud Charlet <charlet@adacore.com>
345 * gnatvsn.ads (Current_Year): Update.
347 2010-01-25 Florian Villoing <villoing@adacore.com>
349 * gnat_ugn.texi: Fix typo.
351 2010-01-25 Thomas Quinot <quinot@adacore.com>
353 * scos.ads: Update specification.
355 2010-01-25 Ed Schonberg <schonberg@adacore.com>
357 * sem_ch6.adb (Process_PPCs): If a postcondition is present and the
358 enclosing subprogram has no previous spec, attach postcondition
359 procedure to the defining entity for the body.
361 2010-01-25 Ed Schonberg <schonberg@adacore.com>
363 * exp_aggr.adb (Build_Record_Aggr_Code); Do not generate call to
364 initialization procedure of the ancestor part of an extension aggregate
365 if it is an interface type.
367 2010-01-25 Vincent Celier <celier@adacore.com>
369 * gnatlink.adb (Process_Binder_File): The directory for the shared
370 version of libgcc in the run path options is found in the subdirectory
371 indicated by __gnat_default_libgcc_subdir.
372 * link.c: Declare new const char * __gnat_default_libgcc_subdir for
375 2010-01-25 Ed Schonberg <schonberg@adacore.com>
377 * sem_prag.adb: More flexible pragma Annotate.
379 2010-01-22 Eric Botcazou <ebotcazou@adacore.com>
381 * system-linux-armel.ads (Stack_Check_Probes): Set to True.
382 * system-linux-armeb.ads (Stack_Check_Probes): Likewise.
384 2010-01-18 Eric Botcazou <ebotcazou@adacore.com>
386 * gcc-interface/utils.c (create_var_decl_1): Fix formatting nits.
388 2010-01-18 Jan Hubicka <jh@suse.cz>
391 * gcc-interface/utils.c (create_var_decl_1): Do not set COMMON flag for
392 unit local variables.
394 2010-01-17 Laurent GUERBY <laurent@guerby.net>
396 * gcc-interface/Makefile.in: Fix typo in arm*-*-linux-gnueabi.
398 2010-01-11 Mikael Pettersson <mikpe@it.uu.se>
400 * gcc-interface/Makefile.in: Add arm*-*-linux-gnueabi.
401 * system-linux-armeb.ads, system-linux-armel.ads: New files.
403 2010-01-09 Simon Wright <simon@pushface.org>
406 * gcc-interface/Makefile.in (gnatlib-shared-darwin): Add missing
411 Copyright (C) 2010 Free Software Foundation, Inc.
413 Copying and distribution of this file, with or without modification,
414 are permitted in any medium without royalty provided the copyright
415 notice and this notice are preserved.