aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada
AgeCommit message (Collapse)AuthorFilesLines
2021-04-12Daily bump.GCC Administrator1-0/+4
2021-04-11ada: Avoid invalid "up" link in manualGerald Pfeifer1-1/+1
gcc/ada/ * gnat_ugn.texi (Top): Avoid invalid "up" link.
2021-03-30Daily bump.GCC Administrator1-0/+6
2021-03-30Fix wrong assignment of aggregate to full-access componentEric Botcazou1-2/+1
This is a regression present on the mainline: the compiler (front-end) fails to assign an aggregate to a full-access component (i.e. Atomic or VFA) as a whole if the type of the component is not full access itself. gcc/ada/ PR ada/99802 * freeze.adb (Is_Full_Access_Aggregate): Call Is_Full_Access_Object on the name of an N_Assignment_Statement to spot full access.
2021-03-11Daily bump.GCC Administrator1-0/+5
2021-03-10Fix ICE on atomic enumeration type with LTOEric Botcazou1-0/+4
This is a strange regression whereby an enumeration type declared as atomic (or volatile) incorrectly triggers the ODR machinery for its values in LTO mode. gcc/ada/ * gcc-interface/decl.c (gnat_to_gnu_entity): Build a TYPE_STUB_DECL for the main variant of an enumeration type declared as volatile. gcc/testsuite/ * gnat.dg/specs/lto25.ads: New test.
2021-03-10Daily bump.GCC Administrator1-0/+5
2021-03-09Re: [PATCH v2] fix Ada bootstrap on Cygwin64 (PR bootstrap/94918)Mikael Pettersson1-0/+6
gcc/ada/ * raise-gcc.c: On Cygwin include mingw32.h to prevent windows.h from including x86intrin.h or emmintrin.h.
2021-03-06Daily bump.GCC Administrator1-0/+7
2021-03-05Fix build breakage with latest glibc releaseEric Botcazou2-7/+3
gcc/ada/ PR ada/99264 * init.c (__gnat_alternate_sta) [Linux]: Remove preprocessor test on MINSIGSTKSZ and bump size to 32KB. * libgnarl/s-osinte__linux.ads (Alternate_Stack_Size): Bump to 32KB.
2021-03-03Daily bump.GCC Administrator1-0/+12
2021-03-02[PATCH] Fix Ada bootstrap failure on Cygwin since switch to C++11 (PR98590)Mikael Pettersson1-0/+5
gcc/ada PR bootstrap/98590 * cstreams.c: Ensure fileno_unlocked() is visible on Cygwin.
2021-03-02Fix PR ada/99095Eric Botcazou1-1/+9
This is a regression present on the mainline and 10 branch, where we fail to make the bounds explicit for the return value of a function returning an unconstrained array of a limited record type. gcc/ada/ PR ada/99095 * sem_ch8.adb (Check_Constrained_Object): Restrict again the special optimization for limited types to non-array types except in the case of an extended return statement. gcc/testsuite/ * gnat.dg/limited5.adb: New test.
2021-03-02Daily bump.GCC Administrator1-0/+6
2021-03-02Do not call Set_Cloned_Subtype on private typeEric Botcazou1-1/+1
Build_Discriminated_Subtype may be invoked on a E_Record_Type_With_Private, in which case it builds a E_Record_Subtype_With_Private which does not have the Cloned_Subtype field. gcc/ada/ PR ada/99020 * sem_ch3.adb (Build_Discriminated_Subtype): Set the Cloned_Subtype only if the type is not private.
2021-02-27Daily bump.GCC Administrator1-0/+7
2021-02-25[PATCH v4 1/2] MIPS: unaligned load: use SImode for SUBREG if OK (PR98996) ↵YunQiang Su1-0/+12
[PATCH v4 2/2] ada: add 128bit operation for MIPS N32 and N64 gcc/ChangeLog: PR target/98996 * config/mips/mips.c (mips_expand_ext_as_unaligned_load): If TARGET_64BIT and dest is SUBREG, we check the width, if it equal to SImode, we use SImode operation, just like what we are doing for REG one. gcc/ada/ChangeLog: PR ada/98996 * Makefile.rtl: <mips*-*-linux*> add 128Bit operation file for MIPS N64 and N32 to LIBGNAT_TARGET_PAIRS and EXTRA_GNATRTL_NONTASKING_OBJS
2021-02-13Daily bump.GCC Administrator1-0/+4
2021-02-12[Ada] Remove unused subprograms (continued)Arnaud Charlet2-4/+103
gcc/ada/ * repinfo.ads, repinfo.adb (*SO_Ref*): Restore.
2021-02-04Daily bump.GCC Administrator1-0/+18
2021-02-03Fix regression with partial rep clause on variant record typeEric Botcazou2-37/+79
It can yield an incorrect layout when there is a partial representation clause on a discriminated record type with a variant part. gcc/ada/ * gcc-interface/decl.c (components_to_record): If the first component with rep clause is the _Parent field with variable size, temporarily set it aside when computing the internal layout of the REP part again. * gcc-interface/utils.c (finish_record_type): Revert to taking the maximum when merging sizes for all record types with rep clause. (merge_sizes): Put SPECIAL parameter last and adjust recursive calls.
2021-02-03Assorted LTO fixes for AdaEric Botcazou2-7/+22
This polishes a few rough edges visible in LTO mode. gcc/ada/ * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Make the two fields of the fat pointer type addressable, and do not make the template type read-only. <E_Record_Type>: If the type has discriminants mark it as may_alias. * gcc-interface/utils.c (make_dummy_type): Likewise. (build_dummy_unc_pointer_types): Likewise.
2021-01-27Daily bump.GCC Administrator1-0/+6
2021-01-26Fix PR ada/98228Eric Botcazou1-1/+1
This is the profiled bootstrap failure for s390x/Linux on the mainline, which has been introduced by the modref pass but actually exposing an existing issue in the maybe_pad_type function that is visible on s390x. The issue is too weak a test for the addressability of the inner component. gcc/ada/ Marius Hillenbrand <mhillen@linux.ibm.com> PR ada/98228 * gcc-interface/utils.c (maybe_pad_type): Test the size of the new packable type instead of its alignment for addressability's sake.
2021-01-26Daily bump.GCC Administrator1-0/+9
2021-01-25Fix internal error on extension with interface at -O2Eric Botcazou2-16/+20
This is a regression present on the mainline, 10 and 9 branches, in the form of an internal error with the Ada compiler when a covariant-only thunk is inlined into its caller. gcc/ada/ * gcc-interface/trans.c (make_covariant_thunk): Set the DECL_CONTEXT of the parameters and do not set TREE_PUBLIC on the thunk. (maybe_make_gnu_thunk): Pass the alias to the covariant thunk. * gcc-interface/utils.c (finish_subprog_decl): Set the DECL_CONTEXT of the parameters here... (begin_subprog_body): ...instead of here. gcc/testsuite/ * gnat.dg/thunk2.adb, gnat.dg/thunk2.ads: New test. * gnat.dg/thunk2_pkg.ads: New helper.
2021-01-20Daily bump.GCC Administrator1-0/+5
2021-01-19Fix PR ada/98740Eric Botcazou1-5/+6
It's a long-standing GENERIC tree sharing issue. gcc/ada/ChangeLog: PR ada/98740 * gcc-interface/trans.c (add_decl_expr): Always mark TYPE_ADA_SIZE.
2021-01-15Daily bump.GCC Administrator1-0/+6
2021-01-14RTEMS: Fix Ada build for riscvSebastian Huber1-0/+5
gcc/ada/ PR ada/98595 * Makefile.rtl (LIBGNAT_TARGET_PAIRS) <riscv*-*-rtems*>: Use wraplf version of Aux_Long_Long_Float.
2021-01-04Daily bump.GCC Administrator1-0/+4
2021-01-03Bump copyright yearEric Botcazou1-1/+1
gcc/ada/ * gnatvsn.ads: Bump copyright year.
2021-01-02Daily bump.GCC Administrator1-0/+9
2021-01-01Update copyright dates.Jakub Jelinek2-2/+2
Manual part of copyright year updates. 2021-01-01 Jakub Jelinek <jakub@redhat.com> gcc/ * gcc.c (process_command): Update copyright notice dates. * gcov-dump.c (print_version): Ditto. * gcov.c (print_version): Ditto. * gcov-tool.c (print_version): Ditto. * gengtype.c (create_file): Ditto. * doc/cpp.texi: Bump @copying's copyright year. * doc/cppinternals.texi: Ditto. * doc/gcc.texi: Ditto. * doc/gccint.texi: Ditto. * doc/gcov.texi: Ditto. * doc/install.texi: Ditto. * doc/invoke.texi: Ditto. gcc/ada/ * gnat_ugn.texi: Bump @copying's copyright year. * gnat_rm.texi: Likewise. gcc/d/ * gdc.texi: Bump @copyrights-d year. gcc/fortran/ * gfortranspec.c (lang_specific_driver): Update copyright notice dates. * gfc-internals.texi: Bump @copying's copyright year. * gfortran.texi: Ditto. * intrinsic.texi: Ditto. * invoke.texi: Ditto. gcc/go/ * gccgo.texi: Bump @copyrights-go year. libgomp/ * libgomp.texi: Bump @copying's copyright year. libitm/ * libitm.texi: Bump @copying's copyright year. libquadmath/ * libquadmath.texi: Bump @copying's copyright year.
2021-01-01Rotate ChangeLog files - step 2 - remove 2020 entries from ChangeLog files.Jakub Jelinek1-13973/+1
Can't be committed together with the previous one due to the ChangeLog vs. other files restrictions.
2021-01-01Rotate ChangeLog files - part 1 - add ChangeLog-2020.Jakub Jelinek1-0/+13978
2021-01-01 Jakub Jelinek <jakub@redhat.com> gcc/ * ChangeLog-2020: Rotate ChangeLog. New file. gcc/ada/ * ChangeLog-2020: Rotate ChangeLog. New file. gcc/cp/ * ChangeLog-2020: Rotate ChangeLog. New file. gcc/d/ * ChangeLog-2020: Rotate ChangeLog. New file. gcc/fortran/ * ChangeLog-2020: Rotate ChangeLog. New file. gcc/testsuite/ * ChangeLog-2020: Rotate ChangeLog. New file. libgfortran/ * ChangeLog-2020: Rotate ChangeLog. New file. libstdc++-v3/ * ChangeLog-2020: Rotate ChangeLog. New file.
2020-12-18Daily bump.GCC Administrator1-0/+370
2020-12-17[Ada] Performance of CW_MembershipArnaud Charlet2-48/+46
gcc/ada/ * libgnat/a-tags.ads, libgnat/a-tags.adb (CW_Membership): Move to spec to allow inlining. gcc/testsuite/ * gnat.dg/debug15.adb: Remove fragile testcase.
2020-12-17[Ada] Remove unused subprograms in validswArnaud Charlet88-1130/+16
gcc/ada/ * checks.adb: Remove, not used. * checks.ads: Likewise. * exp_ch6.adb: Likewise. * exp_ch7.adb: Likewise. * exp_ch7.ads: Likewise. * exp_fixd.adb: Likewise. * exp_tss.adb: Likewise. * exp_tss.ads: Likewise. * exp_util.adb: Likewise. * exp_util.ads: Likewise. * gnat1drv.adb: Likewise. * libgnat/s-finmas.adb: Likewise. * libgnat/s-finmas.ads: Likewise. * libgnat/system-aix.ads: Likewise. * libgnat/system-darwin-arm.ads: Likewise. * libgnat/system-darwin-ppc.ads: Likewise. * libgnat/system-darwin-x86.ads: Likewise. * libgnat/system-djgpp.ads: Likewise. * libgnat/system-dragonfly-x86_64.ads: Likewise. * libgnat/system-freebsd.ads: Likewise. * libgnat/system-hpux-ia64.ads: Likewise. * libgnat/system-hpux.ads: Likewise. * libgnat/system-linux-alpha.ads: Likewise. * libgnat/system-linux-arm.ads: Likewise. * libgnat/system-linux-hppa.ads: Likewise. * libgnat/system-linux-ia64.ads: Likewise. * libgnat/system-linux-m68k.ads: Likewise. * libgnat/system-linux-mips.ads: Likewise. * libgnat/system-linux-ppc.ads: Likewise. * libgnat/system-linux-riscv.ads: Likewise. * libgnat/system-linux-s390.ads: Likewise. * libgnat/system-linux-sh4.ads: Likewise. * libgnat/system-linux-sparc.ads: Likewise. * libgnat/system-linux-x86.ads: Likewise. * libgnat/system-lynxos178-ppc.ads: Likewise. * libgnat/system-lynxos178-x86.ads: Likewise. * libgnat/system-mingw.ads: Likewise. * libgnat/system-qnx-aarch64.ads: Likewise. * libgnat/system-rtems.ads: Likewise. * libgnat/system-solaris-sparc.ads: Likewise. * libgnat/system-solaris-x86.ads: Likewise. * libgnat/system-vxworks-arm-rtp-smp.ads: Likewise. * libgnat/system-vxworks-arm-rtp.ads: Likewise. * libgnat/system-vxworks-arm.ads: Likewise. * libgnat/system-vxworks-e500-kernel.ads: Likewise. * libgnat/system-vxworks-e500-rtp-smp.ads: Likewise. * libgnat/system-vxworks-e500-rtp.ads: Likewise. * libgnat/system-vxworks-e500-vthread.ads: Likewise. * libgnat/system-vxworks-ppc-kernel.ads: Likewise. * libgnat/system-vxworks-ppc-ravenscar.ads: Likewise. * libgnat/system-vxworks-ppc-rtp-smp.ads: Likewise. * libgnat/system-vxworks-ppc-rtp.ads: Likewise. * libgnat/system-vxworks-ppc-vthread.ads: Likewise. * libgnat/system-vxworks-ppc.ads: Likewise. * libgnat/system-vxworks-x86-kernel.ads: Likewise. * libgnat/system-vxworks-x86-rtp-smp.ads: Likewise. * libgnat/system-vxworks-x86-rtp.ads: Likewise. * libgnat/system-vxworks-x86-vthread.ads: Likewise. * libgnat/system-vxworks-x86.ads: Likewise. * libgnat/system-vxworks7-aarch64-rtp-smp.ads: Likewise. * libgnat/system-vxworks7-aarch64.ads: Likewise. * libgnat/system-vxworks7-arm-rtp-smp.ads: Likewise. * libgnat/system-vxworks7-arm.ads: Likewise. * libgnat/system-vxworks7-e500-kernel.ads: Likewise. * libgnat/system-vxworks7-e500-rtp-smp.ads: Likewise. * libgnat/system-vxworks7-e500-rtp.ads: Likewise. * libgnat/system-vxworks7-ppc-kernel.ads: Likewise. * libgnat/system-vxworks7-ppc-rtp-smp.ads: Likewise. * libgnat/system-vxworks7-ppc-rtp.ads: Likewise. * libgnat/system-vxworks7-ppc64-kernel.ads: Likewise. * libgnat/system-vxworks7-ppc64-rtp-smp.ads: Likewise. * libgnat/system-vxworks7-x86-kernel.ads: Likewise. * libgnat/system-vxworks7-x86-rtp-smp.ads: Likewise. * libgnat/system-vxworks7-x86-rtp.ads: Likewise. * libgnat/system-vxworks7-x86_64-kernel.ads: Likewise. * libgnat/system-vxworks7-x86_64-rtp-smp.ads: Likewise. * repinfo.adb: Likewise. * repinfo.ads: Likewise. * rtsfind.ads: Likewise. * sem_aux.adb: Likewise. * sem_aux.ads: Likewise. * sem_ch13.adb: Likewise. * sem_ch13.ads: Likewise. * sem_util.adb (Validity_Checks_Suppressed, TSS, Is_All_Null_Statements, Known_Non_Negative, Non_Limited_Designated_Type, Get_Binary_Nkind, Get_Unary_Nkind, Is_Protected_Operation, Number_Components, Package_Body, Validate_Independence, Independence_Checks): Likewise; update comments. * targparm.adb: Likewise. * targparm.ads (AAM, AAM_Str, Fractional_Fixed_Ops, Frontend_Layout, Make_Detach_Call, Target_Has_Fixed_Ops, Detach, Back_End_Layout, Create_Dynamic_SO_Ref, Get_Dynamic_SO_Entity, Is_Dynamic_SO_Ref, Is_Static_SO_Ref, Fractional_Fixed_Ops_On_Target): Likewise. * validsw.adb (Save_Validity_Check_Options, Set_Default_Validity_Check_Options): Likewise. * validsw.ads: Likewise.
2020-12-17[Ada] Remove unused filesArnaud Charlet2-205/+0
gcc/ada/ * symbols.ads, symbols.adb: Removed no longer used.
2020-12-17[Ada] Code cleanup: remove Old_Requires_Transient_ScopeArnaud Charlet2-400/+218
gcc/ada/ * sem_util.adb (New_Requires_Transient_Scope): Renamed Requires_Transient_Scope. (Requires_Transient_Scope, Old_Requires_Transient_Scope, Results_Differ): Removed. * debug.adb: Remove -gnatdQ.
2020-12-17[Ada] Minor comment fix in System.Val_RealEric Botcazou1-4/+4
gcc/ada/ * libgnat/s-valrea.adb (Need_Extra): Fix comment.
2020-12-17[Ada] Prevent early exits without restoring a global variablePiotr Trojanek1-2/+3
gcc/ada/ * sem_ch5.adb (Analyze_Case_Statement): Move modification of Unblocked_Exit_Count after early return statements; fix typo in comment.
2020-12-17[Ada] Reduce scopes of local variables for case and if statementsPiotr Trojanek1-16/+17
gcc/ada/ * sem_ch5.adb (Analyze_Case_Statement): Change local variable Exp to constant; remove unreferenced Last_Choice variable; reduce scope of other variables. (Analyze_If_Statement): Reduce scope of a local variable; add comment.
2020-12-17[Ada] Refine type of a multi unit index numberPiotr Trojanek1-1/+1
gcc/ada/ * opt.ads (Multiple_Unit_Index): Refine type from Int to Nat.
2020-12-17[Ada] Prevent In_Check_Node routine from going too far in the parent chainPiotr Trojanek1-5/+11
gcc/ada/ * sem_util.adb (In_Check_Node): Add guard and rename Node to Par, just like it is done in surrounding routines, e.g. In_Assertion_Expression_Pragma and In_Generic_Formal_Package.
2020-12-17[Ada] Ada2020: AI12-0400 Ambiguities associated with VectorBob Duff12-169/+261
gcc/ada/ * libgnat/a-cbdlli.adb, libgnat/a-cbdlli.ads, libgnat/a-cdlili.adb, libgnat/a-cdlili.ads, libgnat/a-cidlli.adb, libgnat/a-cidlli.ads, libgnat/a-cobove.adb, libgnat/a-cobove.ads, libgnat/a-coinve.adb, libgnat/a-coinve.ads, libgnat/a-convec.adb, libgnat/a-convec.ads: Add *_Vector operations, remove default for Count, rename Append_One to be Append.
2020-12-17[Ada] Crash on if expression inside declare expressionArnaud Charlet3-11/+32
gcc/ada/ * sem_res.adb (Resolve_Declare_Expression): Need to establish a transient scope in case Expression (N) requires actions to be wrapped. Code cleanup. * exp_ch7.adb, exp_ch11.adb: Code cleanup.
2020-12-17[Ada] Consistent wording for missing -gnat2020 switchPiotr Trojanek6-35/+18
gcc/ada/ * par-ch3.adb (P_Identifier_Declarations): Reuse Error_Msg_Ada_2020_Feature for object renaming without subtype. * par-ch4.adb (P_Primary): Likewise for target name. (P_Iterated_Component_Association): Likewise for iterated component. (P_Declare_Expression): Likewise for declare expression. * par-ch6.adb (P_Formal_Part): Likewise for aspect on formal parameter. * sem_aggr.adb (Resolve_Delta_Aggregate): Ditto. * sem_ch8.adb (Analyze_Object_Renaming): Reuse Error_Msg_Ada_2020_Feature. * sem_ch13.adb (Validate_Aspect_Aggregate): Reuse Error_Msg_Ada_2020_Feature; use lower case for "aspect" and don't use underscore for "Ada_2020"; don't give up on analysis in Ada 2012 mode. (Validate_Aspect_Stable_Properties): Reuse Error_Msg_Ada_2020_Feature; use lower case for "aspect"; minor style fixes.
2020-12-17[Ada] Remove discriminant checks processing in gigiArnaud Charlet12-121/+353
gcc/ada/ * sem_ch4.adb (Analyze_Selected_Component): Request a compile time error replacement in Apply_Compile_Time_Constraint_Error in case of an invalid field. * sem_ch3.adb (Create_Constrained_Components): Take advantage of Gather_Components also in the case of a record extension and also constrain records in the case of compile time known discriminant values, as already done in gigi. * sem_util.ads, sem_util.adb (Gather_Components): New parameter Allow_Compile_Time to allow compile time known (but non static) discriminant values, needed by Create_Constrained_Components, and new parameter Include_Interface_Tag. (Is_Dependent_Component_Of_Mutable_Object): Use Original_Node to perform check on the original tree. (Is_Object_Reference): Likewise. Only call Original_Node when relevant via a new function Safe_Prefix. (Is_Static_Discriminant_Component, In_Check_Node): New. (Is_Actual_Out_Or_In_Out_Parameter): New. * exp_ch4.adb (Expand_N_Selected_Component): Remove no longer needed code preventing evaluating statically discriminants in more cases. * exp_ch5.adb (Expand_N_Loop_Statement): Simplify expansion of loops with an N_Raise_xxx_Error node to avoid confusing the code generator. (Make_Component_List_Assign): Try to find a constrained type to extract discriminant values from, so that the case statement built gets an opportunity to be folded by Expand_N_Case_Statement. (Expand_Assign_Record): Update comments, code cleanups. * sem_attr.adb (Analyze_Attribute): Perform most of the analysis on the original prefix node to deal properly with a prefix rewritten as a N_Raise_xxx_Error. * sem_ch5.adb (Analyze_Loop_Parameter_Specification): Handle properly a discrete subtype definition being rewritten as N_Raise_xxx_Error. * sem_ch8.adb (Analyze_Object_Renaming): Handle N_Raise_xxx_Error nodes as part of the expression being renamed. * sem_eval.ads, sem_eval.adb (Fold, Eval_Selected_Component): New. (Compile_Time_Known_Value, Expr_Value, Expr_Rep_Value): Evaluate static discriminant component values. * sem_res.adb (Resolve_Selected_Component): Call Eval_Selected_Component.