aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada
AgeCommit message (Collapse)AuthorFilesLines
2024-12-13ada: Fix code indentationPiotr Trojanek34-253/+254
Fix uncontroversial coding style violations detected by an experiment with a tree-sitter indentation support in Emacs. gcc/ada/ChangeLog: * atree.adb, diagnostics-pretty_emitter.adb, diagnostics-utils.adb, einfo-utils.adb, errout.adb, exp_aggr.adb, exp_ch3.adb, exp_ch5.adb, exp_ch6.adb, exp_ch7.adb, exp_imgv.adb, exp_pakd.adb, exp_prag.adb, exp_unst.adb, exp_util.adb, gnatchop.adb, gnatlink.adb, inline.adb, itypes.adb, osint.adb, rtsfind.adb, sem_aggr.adb, sem_ch10.adb, sem_ch12.adb, sem_ch13.adb, sem_ch3.adb, sem_ch4.adb, sem_dim.adb, sem_elab.adb, sem_prag.adb, sem_util.adb, sprint.adb, switch-m.adb, table.adb: Fix code indentation.
2024-12-13ada: Fix fixed point text-io when subtype has dynamic rangeMarc Poulhiès6-150/+210
When the fixed point subtype has dynamic range, for example in the context of a generic procedure Test where Fixed_Type is a type formal: procedure Test (Low, High : Fixed_Type) is type New_Subtype is new Fixed_Type range Low .. High; package New_Io is new Text_IO.Fixed_IO (New_Subtype); the compiler would complain with: non-static universal integer value out of range Have the check use the Base type for checking what integer type can be used. If a given integer type can be used for a base type, it can also be used for any of its subtypes. gcc/ada/ChangeLog: * libgnat/a-tifiio.adb (OK_Get_32): Use 'Base. (OK_Put_32, OK_Get_64, OK_Put_64): Likewise. * libgnat/a-tifiio__128.adb (OK_Get_32, OK_Put_32, OK_Get_64) (OK_Put_64, OK_Get_128, OK_Put_128): Likewise. * libgnat/a-wtfiio.adb (OK_Get_32): Likewise. (OK_Put_32, OK_Get_64, OK_Put_64): Likewise. * libgnat/a-wtfiio__128.adb (OK_Get_32, OK_Put_32, OK_Get_64) (OK_Put_64, OK_Get_128, OK_Put_128): Likewise. * libgnat/a-ztfiio.adb (OK_Get_32): Likewise. (OK_Put_32, OK_Get_64, OK_Put_64): Likewise. * libgnat/a-ztfiio__128.adb (OK_Get_32, OK_Put_32, OK_Get_64) (OK_Put_64, OK_Get_128, OK_Put_128): Likewise.
2024-12-13ada: Refactor code of Check_Ambiguous_Call and Valid_ConversionJavier Miranda1-17/+7
gcc/ada/ChangeLog: * sem_res.adb (Report_Ambiguous_Argument): Code cleanup. (Resolve): Code cleanup.
2024-12-13ada: Implement new rules about effectively volatile types in SPARKPiotr Trojanek2-0/+53
New rules make record types effectively volatile based on the effective volatility of their components; same for effectively volatile for reading. Now volatility composition for records works like volatility composition for arrays. gcc/ada/ChangeLog: * sem_util.adb (Is_Effectively_Volatile, Is_Effectively_Volatile_For_Reading): Implement new rule for record types. * sem_util.ads (Is_Effectively_Volatile, Is_Effectively_Volatile_For_Reading): Adjust comments.
2024-12-13ada: Remove unused parameter from volatile type queriesPiotr Trojanek2-38/+12
Routines Is_Effectively_Volatile and Is_Effectively_Volatile_For_Reading were always called with Ignore_Protected parameter set to True (or has been passed unmodified on recursive calls), so this parameter wasn't actually needed. Code cleanup; semantics is unaffected. gcc/ada/ChangeLog: * sem_util.adb (Is_Effectively_Volatile, Is_Effectively_Volatile_For_Reading): Remove Ignore_Protected parameter. (Is_Effectively_Volatile_Object, Is_Effectively_Volatile_Object_For_Reading): Remove single-parameter wrappers that are needed to instantiate generic subprogram. * sem_util.ads (Is_Effectively_Volatile, Is_Effectively_Volatile_For_Reading): Remove parameter; adjust comment.
2024-12-13ada: Elide copy for calls in allocators for nonlimited by-reference typesEric Botcazou3-36/+36
This prevents a temporary from being created on the primary stack to hold the result of the function calls before it is copied to the newly allocated memory in the nonlimited by-reference case. That's already not done in the nonlimited non-by-reference case and there is no reason to do it in the former case either. The main issue is the call to Remove_Side_Effects in Expand_Allocator_Expression, but its only purpose is to cover the problematic processing done in Build_Allocate_Deallocate_Proc on (part of) the expression; once this is fixed, the call is unnecessary. The change also contains another small fix to deal with the corner case of allocators for access-to-access types. gcc/ada/ChangeLog: * exp_ch4.adb (Expand_Allocator_Expression): Do not preventively call Remove_Side_Effects on the expression in the nonlimited by-reference case. Always call Build_Allocate_Deallocate_Proc in the default case. * exp_ch6.adb (Expand_Ctrl_Function_Call): Bail out if the call is the qualified expression of an allocator. * exp_util.adb (Build_Allocate_Deallocate_Proc): Replace all the calls to Relocate_Node by calls to Duplicate_Subexpr_No_Checks.
2024-12-13ada: Remove last call to Preanalyze_And_Resolve from Exp_AggrEric Botcazou1-4/+1
All the expressions are now at least preanalyzed in a non-iterated context, so we do not need to redo it in Aggr_Assignment_OK_For_Backend, given that Is_OK_Aggregate explicitly rejects iterated component associations. gcc/ada/ChangeLog: * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Do not call again Preanalyze_And_Resolve on the expression.
2024-12-13ada: Fix breakage of GNATprove introduced by latest changeEric Botcazou1-2/+3
gcc/ada/ChangeLog: * sem_aggr.adb (Resolve_Aggr_Expr): Always perform a full analysis of the expression in SPARK mode.
2024-12-13ada: Fix typo in reference manualRonan Desplanques3-3/+3
gcc/ada/ChangeLog: * doc/gnat_rm/gnat_language_extensions.rst: Fix typo. * gnat_rm.texi: Regenerate. * gnat_ugn.texi: Regenerate.
2024-12-13ada: Fix dangling reference with user-defined indexing of function callEric Botcazou1-0/+36
This happens with a noncontrolled type because the user-defined indexing is expanded into a function call that binds the lifetime of the original call to its return value. The temporary must be created explicitly in this case, so that the front-end can control its lifetime. gcc/ada/ChangeLog: * exp_ch6.adb (Expand_Call_Helper): Also create a temporary in the case of a noncontrolled user-defined indexing.
2024-12-13ada: Fix documentation of Ada.Real_Time.Timing_EventsRonan Desplanques3-3/+5
The GNAT reference manual stated that GNAT did not implement this language-defined package, but GNAT in fact does offer an implementation of it. gcc/ada/ChangeLog: * doc/gnat_rm/standard_library_routines.rst: Fix documentation. * gnat_rm.texi: Regenerate. * gnat_ugn.texi: Regenerate.
2024-12-13ada: Exclude library units from gnatcov instrumentationRonan Desplanques1-1/+18
Before this patch, we instrumented code that's only used during the build process to generate more code. This patch marks the code-generating code so it's not instrumented for coverage. gcc/ada/ChangeLog: * gnat2.gpr: Add library units to coverage exclusion list.
2024-12-13ada: Further work in semantic analysis of iterated component associationsEric Botcazou2-126/+86
This finishes up the transition to preanalysis of a copy of the expression for iterated component associations in all contexts, thus voiding the need to clean things up afterward. However, this requires a larger cleanup in semantics analysis of aggregates, in particular for others choices, which are currently skipped in Sem_Aggr, with Exp_Aggr trying to patch things up afterward but leaving some legality loopholes in the end. That's why this makes sure that all the expressions appearing in aggregates are either analyzed or preanalyzed by Sem_Aggr, as documented in the spec of Sem, modulo the copy in an iteration context. gcc/ada/ChangeLog: * exp_aggr.adb (Build_Array_Aggr_Code): Remove obsolete comment. (Convert_To_Positional): Remove Ctyp local variable. (Is_Static_Element): Remove Dims parameter and do not preanalyze the expression there. (Expand_Array_Aggregate): Make Ctyp a constant. (Compute_Others_Present): Do not preanalyze the expression there. * sem_aggr.adb (Resolve_Array_Aggregate): New Ctyp constant. Use it throughout the procedure to denote the component type. (Resolve_Aggr_Expr): Always preanalyze a copy of the expression in an iteration context. Preanalyze it directly when the expander is active and the choice may cover multiple components. Otherwise, fully analyze it. Do not reanalyze an iterated component association with an others choice either when there are positional components. (Resolve_Iterated_Component_Association): Do not remove references from the expression after invoking Resolve_Aggr_Expr on it.
2024-12-13ada: Remove implicit assumption in the double caseEric Botcazou1-7/+16
The assumption is fulfilled in all the instantiations of the package, but it should not be made in the generic code. gcc/ada/ChangeLog: * libgnat/s-imager.adb (Set_Image_Real): In the case where a double integer is needed, do not implicit assume that it can contain up to 'Digits of the floating-point type.
2024-12-13ada: Adjust cut-off for scaling of floating-point numbersEric Botcazou1-8/+7
The value needs to take into account denormals and encompass Maxdigs. gcc/ada/ChangeLog: * libgnat/s-imager.adb (Maxscaling): Change to Natural constant and add Maxdigs to value.
2024-12-13Daily bump.GCC Administrator1-0/+219
2024-12-12Fix precondition failure with Ada.Numerics.Generic_Real_Arrays.EigenvaluesEric Botcazou1-10/+14
This fixes a precondition failure triggered when the Eigenvalues routine of Ada.Numerics.Generic_Real_Arrays is instantiated with -gnata, beause it calls Sort_Eigensystem on an empty vector. gcc/ada PR ada/117996 * libgnat/a-ngrear.adb (Jacobi): Remove default value for Compute_Vectors formal parameter. (Sort_Eigensystem): Add Compute_Vectors formal parameter. Do not modify the Vectors if Compute_Vectors is False. (Eigensystem): Pass True as Compute_Vectors to Sort_Eigensystem. (Eigenvalues): Pass False as Compute_Vectors to Sort_Eigensystem. gcc/testsuite * gnat.dg/matrix1.adb: New test.
2024-12-12ada: Fix reference to Ada 2020 in commentPiotr Trojanek1-1/+1
Code cleanup. gcc/ada/ChangeLog: * par-ch5.adb (Test_Statement_Required): Fix comment.
2024-12-12ada: Elide the copy for bit-packed aggregates in object declarationsEric Botcazou2-9/+35
The in-place expansion has been historically disabled for them, but there does not seem to be any good reason left for this. However, this requires a small trick in order for the expanded code not to be flagged as using the object uninitialized by the code generator. gcc/ada/ChangeLog: * exp_aggr.adb (Convert_Aggr_In_Object_Decl): Clear the component referenced on the right-hand side of the first assignment generated for a bit-packed array, if any. (Expand_Array_Aggregate): Do not exclude aggregates of bit-packed array types in object declarations from in-place expansion. * sem_eval.adb (Eval_Indexed_Component): Do not attempt a constant evaluation for a bit-packed array type.
2024-12-12ada: Defend against risk of infinite loopRonan Desplanques1-1/+3
A recently fixed bug caused an infinite loop when assertions were not checked. With assertions checked, the symptom was just an internal error caused by an assertion failure. This patch makes it so that if another bug ever causes the same condition to fail, there will never be an infinite loop with any assertion policy. gcc/ada/ChangeLog: * sem_ch3.adb (Access_Subprogram_Declaration): Replace assertion with more defensive code.
2024-12-12ada: Avoid going through symlinks in the json reportViljar Indus1-1/+2
gcc/ada/ChangeLog: * errout.adb (Write_JSON_Location): Avoid going through symbolic links when printing the full name.
2024-12-12ada: Fix minor display issue on invalid floatsRonan Desplanques1-1/+4
GNAT implements a format with trailing '*' signs for the Image attribute of NaN, +inf and -inf. It was probably always intended to be the same length as the image of 1.0, but one '*' was actually missing. This patch fixes this. gcc/ada/ChangeLog: * libgnat/s-imager.adb (Image_Floating_Point): Tweak display of invalid floating point values.
2024-12-12ada: Improve task entry context detectionRonan Desplanques2-7/+10
Access parameters are not allowed in specifications of task entries. Before this patch, the compiler failed to detect that case in accept statements that were not directly in their task body's scopes. This patch fixes this issue. gcc/ada/ChangeLog: * sem_ch3.adb (Access_Definition): Remove test for task entry context. * sem_ch6.adb (Process_Formals): Add improved test for task entry context.
2024-12-12ada: Refactor warning about null loopsPiotr Trojanek1-8/+9
Code cleanup; semantics is unaffected. gcc/ada/ChangeLog: * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Move call to Comes_From_Source to the outer if-statement.
2024-12-12ada: Fix internal error on loop parameter specificationsPiotr Trojanek1-7/+13
Originally loop parameter specification only occurred in loops, but now it also occurs in quantified expressions. This patch guards against flagging non-loop nodes as null loop statements. This was causing internal compiler errors that were only visible with switch -gnatdk, which happens to be default in GNATprove testsuite. gcc/ada/ChangeLog: * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Only set flag Is_Null_Loop when loop parameter specification comes from a loop and not from a quantified expression.
2024-12-12ada: Elide the copy for bit-packed aggregates in allocatorsEric Botcazou1-7/+4
The in-place expansion has been historically disabled for them, but there does not seem to be any good reason left for this. gcc/ada/ChangeLog: * exp_aggr.adb (Expand_Array_Aggregate): Do not exclude aggregates of bit-packed array types in allocators from in-place expansion.
2024-12-12ada: Fix the level of the LLVM chapter in the User's GuideSebastian Poeplau2-7/+7
gcc/ada/ChangeLog: * doc/gnat_ugn/building_executable_programs_with_gnat.rst: Move the LLVM chapter one level up. * gnat_ugn.texi: Regenerate.
2024-12-12ada: Accept static strings with External_InitializationRonan Desplanques5-70/+91
Before this patch, the argument to the External_Initialization aspect had to be a string literal. This patch extends the possibilities so that any static string is accepted. A new helper function, Is_OK_Static_Expression_Of_Type, is introduced, and in addition to the main change of this patch a couple of calls to that helper function are added in other places to replace equivalent inline code. gcc/ada/ChangeLog: * sem_eval.ads (Is_OK_Static_Expression_Of_Type): New function. * sem_eval.adb (Is_OK_Static_Expression_Of_Type): Likewise. * sem_ch13.adb (Check_Expr_Is_OK_Static_Expression): Use new function. * sem_prag.adb (Check_Expr_Is_OK_Static_Expression): Likewise. * sem_ch3.adb (Apply_External_Initialization): Accept static strings for the parameter.
2024-12-12ada: Fix reference manual clausesRonan Desplanques10-15/+17
The clauses in section 3.5 of the reference manual were moved around along the different Ada versions, which caused some comments in our source code to go out of date. This patch updates the references in those comments. gcc/ada/ChangeLog: * libgnat/a-tifiio.adb: Fix comment. * libgnat/a-tifiio__128.adb: Likewise. * libgnat/s-imaged.ads (Image_Decimal): Likewise. * libgnat/s-imagef.ads (Image_Fixed): Likewise. * libgnat/s-imager.ads (Image_Fixed_Point): Likewise. * libgnat/s-imde32.ads (Image_Decimal32): Likewise. * libgnat/s-imfi64.ads (Image_Fixed64): Likewise. * libgnat/s-imgcha.adb (Image_Character): Likewise. * libgnat/s-valuer.adb (Scan_Raw_Real): Likewise. * sem_attr.adb (Eval_Attribute): Likewise.
2024-12-12ada: Fix pragma Compile_Time_Error for sizes of nonstatic array typesEric Botcazou1-1/+8
The pragma is consistenly rejected for the sizes of nonstatic array types because Eval_Attribute does not evaluate it even if it is known. gcc/ada/ChangeLog: * sem_attr.adb (Eval_Attribute): Treat the various size attributes like Component_Size for nonstatic array types.
2024-12-12ada: Refactor code of Check_Ambiguous_Call and Valid_ConversionJavier Miranda1-2/+1
gcc/ada/ChangeLog: * sem_res.adb (Is_Ambiguous_Operand): Add missing decoration of the operand when it is labeled overloaded but has just one interpretation.
2024-12-12ada: Minor refactoring in expansion of array aggregatesEric Botcazou1-44/+60
This just moves a couple of checks done in conjunction with the predicate Aggr_Assignment_OK_For_Backend into its body and adds a couple of comments. No functional changes. gcc/ada/ChangeLog: * exp_aggr.adb (Aggr_Assignment_OK_For_Backend): Add Target formal parameter and check that it is not a bit-aligned component or slice. Return False in CodePeer mode as well. (Build_Array_Aggr_Code): Remove redundant tests done in conjunction with a call to Aggr_Assignment_OK_For_Backend. (Expand_Array_Aggregate): Likewise. Add a couple of comments and improve formatting.
2024-12-12ada: Fix validity check for private typesRonan Desplanques1-2/+2
Before this patch, the machinery to generate validity checks got confused in some situations involving private views of types, and ended up generating incorrect conversions from floating point types to integer types. This patch fixes this. gcc/ada/ChangeLog: * exp_attr.adb (Expand_N_Attribute_Reference): Fix computation of type category.
2024-12-12ada: Add minimal support for other delayed aspects on controlled objectsEric Botcazou5-82/+58
This extends the processing done for the Address aspect to other delayed aspects. The External_Name aspect is also reclassified as a representation aspect and the three representation aspects External_Name, Link_Name and Linker_Section are moved from the Always_Delay to the Rep_Aspect category, which makes it possible not to delay them in most cases with a small tweak. gcc/ada/ChangeLog: * aspects.ads (Is_Representation_Aspect): True for External_Name. (Aspect_Delay): Use Rep_Aspect for External_Name, Link_Name and Linker_Section. * einfo.ads (Initialization_Statements): Document extended usage. * exp_util.adb (Needs_Initialization_Statements): Return True for all delayed aspects. * freeze.adb (Check_Address_Clause): Do not move the initialization expression here... (Freeze_Object_Declaration): ...but here instead, as well as for all delayed aspects. Remove test for pragma Linker_Section. * sem_ch13.adb (Analyze_One_Aspect): Do not delay in the Rep_Aspect case if the expression is a string literal.
2024-12-12ada: Fix documentation comment for Scan_SignRonan Desplanques1-7/+6
This patches fixes a couple of details that were wrong in the documentation comment for System.Val_Util.Scan_Sign. gcc/ada/ChangeLog: * libgnat/s-valuti.ads (Scan_Sign): Fix documentation comment.
2024-12-12ada: Crash on assignment of task allocator with expanded nameBob Duff1-13/+18
The compiler crashes on an assignment statement of the form "X.Y := new T;", where X.Y is an expanded name (i.e. not a record component or similar) and T is a type containing tasks. gcc/ada/ChangeLog: * exp_util.adb (Build_Task_Image_Decls): Deal properly with the case of an expanded name. Minor cleanup: use a case statement instead of if/elsif chain.
2024-12-12ada: Lift technical limitation in expansion of record aggregatesEric Botcazou1-8/+82
The mechanim deferring the expansion of record aggregates nested in other aggregates with intermediate conditional expressions is disabled in the case where they contain self-references, because of a technical limitation in the replacements done by Build_Record_Aggr_Code. This change lifts it. gcc/ada/ChangeLog: * exp_aggr.adb (Traverse_Proc_For_Aggregate): New generic procedure. (Replace_Discriminants): Instantiate it instead of Traverse_Proc. (Replace_Self_Reference): Likewise. (Convert_To_Assignments): Remove limitation for nested aggregates that contain self-references.
2024-12-12ada: Small improvements to expansion of conditional expressionsEric Botcazou1-171/+141
They comprise using a nonnull accesss type for the indirect expansion to avoid useless checks, smplifying the expansion of if expressions whose condition is known at compile time to avoid an N_Expression_With_Actions, using the indirect expansion for them in the indefinite case too, which makes the special case for an unconstrained array type obsolete. No functional changes. gcc/ada/ChangeLog: * exp_ch4.adb (Expand_N_Case_Expression): Remove obsolete comment about C code generation. Do not create a useless target type if the parent statement is rewritten instead of the expression. Use a nonnull accesss type for the expansion done for composite types. (Expand_N_If_Expression): Simplify the expansion when the condition is known at compile time. Apply the expansion done for by-reference types to indefinite types and remove the obsolete special case for unconstrained array types Use a nonnull access type in this case. Rename New_If local variable to If_Stmt for the sake of consistency.
2024-12-12ada: Fix wrong finalization with private unconstrained array typeEric Botcazou2-4/+10
The address passed to the routine attaching a controlled object to the finalization master must be that of its dope vector for an object whose nominal subtype is an unconstrained array type, but this is not the case when this subtype has a private declaration. gcc/ada/ChangeLog: * exp_ch7.adb (Make_Address_For_Finalize): Look at the underlying subtype to detect the unconstrained array type case. * sprint.adb (Write_Itype) <E_Private_Subtype>: New case.
2024-12-12ada: Update documentation for External_InitializationRonan Desplanques3-5/+5
This fixes an omission in the recent change that was made to file lookup for External_Initialization. gcc/ada/ChangeLog: * doc/gnat_rm/gnat_language_extensions.rst: Update External_Initialization section. * gnat_rm.texi: Regenerate. * gnat_ugn.texi: Regenerate.
2024-12-12ada: Tweak Is_Predefined_File_NameRonan Desplanques1-10/+13
This patch slightly widens the set of filenames that the compiler considers predefined. That makes it possible to build the GNAT runtime using only the file mapping facilities of the compiler, without having to rename files. gcc/ada/ChangeLog: * fname.adb (Is_Predefined_File_Name): Tweak test.
2024-12-12ada: Restrict External_Initialization file lookupRonan Desplanques1-4/+37
Before this patch, External_Initialization looked for files in all directories of the source search path, which led to inconsistencies in some cases. This patch restricts the file lookup so the argument is interpreted as relative to the current source file's directory only. gcc/ada/ChangeLog: * sem_ch3.adb (Apply_External_Initialization): Restrict File lookup.
2024-12-12ada: Clean up and restrict usage of Initialization_StatementsEric Botcazou8-148/+94
This mechanism is the only producer of N_Compound_Statement in the expanded code and parks the statements generated for the in-place initialization of objects by an aggregate, so that they can be moved to the freeze point if there is an address aspect/clause, or even cancelled if the aggregate has been generated for Initialize_Scalars/Normalize_Scalars before a subsequent pragma Import for the object is encountered. The main condition for its triggering is that the object be not yet frozen, but that's always the case when its declaration is being processed, so the mechanism is triggered unnecessarily and the change restricts this but, on the other hand, it also extends its usage to the in-place initialization by a function call, which was implemented by means of a custom deferral. There should be no functional changes. gcc/ada/ChangeLog: * einfo.ads (Initialization_Statements): Document usage precisely. * exp_aggr.adb (Convert_Aggr_In_Object_Decl): Do not create a compound statement in most cases, do it only if necessary. * exp_ch3.adb (Expand_N_Object_Declaration): Remove a couple of useless statements. * exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): Use the Initialization_Statements mechanism if necessary. * exp_ch7.adb: Remove clauses for Aspects package. (Insert_Actions_In_Scope_Around): Use the support code of Exp_Util for the Initialization_Statements mechanism. * exp_prag.adb (Undo_Initialization): Remove obsolete code. * exp_util.ads (Move_To_Initialization_Statements): New procedure. (Needs_Initialization_Statements): New function. * exp_util.adb (Move_To_Initialization_Statements): New procedure. (Needs_Initialization_Statements): New predicate.
2024-12-12ada: Avoid expanding LHS assignments for controlled typesViljar Indus1-0/+7
Expanding a function call that returns a controlled type on the left-hand side of an assignment should be avoided. Otherwise we will miss the diagnostic for trying to assign something to a non-variable element. gcc/ada/ChangeLog: * exp_ch6.adb (Expand_Ctrl_Function_Call): Avoid expansion of controlled types when the LHS is a function call.
2024-12-12ada: Add SIGPROT handler for CheriBSDDaniel King1-0/+79
gcc/ada/ChangeLog: * init.c (__gnat_error_handler): Handle SIGPROT (__gnat_install_handler): Install SIGPROT handler
2024-12-12ada: Export CHERI exception IDsDaniel King1-0/+30
This allows CHERI exceptions to be raised from C code in the runtime. gcc/ada/ChangeLog: * libgnat/i-cheri-exceptions.ads: Export CHERI exception IDs.
2024-12-12ada: Ensure minimum stack size for preallocated task stacksJohannes Kliemann2-0/+31
On targets with preallocated task stacks the minimum stack size is defined as a constant in System.Parameters. When adding preallocated tasks to the expanded code the compiler does not have direct access to that value. Instead generate the expression Max (Task_Size, Minimum_Task_Size) in the expanded tree and let it be resolved later in the compilation process. gcc/ada/ChangeLog: * exp_ch9.adb (Expand_N_Task_Type_Declaration): Take Minimum_Stack_Size into account when preallocating task stacks. * rtsfind.ads (RE_Id, RE_Unit_Table): Add RE_Minimum_Stack_Size.
2024-12-12Daily bump.GCC Administrator1-0/+21
2024-12-11Ada: Add GNU/Hurd x86_64 supportSamuel Thibault1-0/+36
This is essentially the same as the i386-pc-gnu section, the differences are the same as between freebsd i386 and freebsd x86_64. gcc/ada/ChangeLog: * Makefile.rtl: Add x86_64-pc-gnu section. Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
2024-12-11Ada: Fix GNU/Hurd priority rangeSamuel Thibault2-1/+149
GNU/Mach currently uses a 0..63 range. gcc/ada/ChangeLog: * libgnat/system-gnu.ads: New file. * Makefile.rtl (x86-gnuhurd): Use libgnat/system-gnu.ads instead of libgnat/system-freebsd.ads. Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>