2025-05-07 Jakub Jelinek PR libfortran/120153 * Makefile.am (i_maxloc1_c): Add generated/maxloc1_16_m16.c. * intrinsics/random.c (arandom_m16): Use #ifdef HAVE_GFC_UINTEGER_16 guard rather than #ifdef GFC_HAVE_GFC_UINTEGER_16. * gfortran.map (GFORTRAN_15): Remove _gfortran_arandom_m16, _gfortran_maxloc1_16_m16, _gfortran_mmaxloc1_16_m16 and _gfortran_smaxloc1_16_m16. (GFORTRAN_15.2): New symbol version, add those 4 symbols to it. * generated/maxloc1_16_m16.c: New file. * Makefile.in: Regenerate. 2025-05-07 Jakub Jelinek PR libfortran/120152 * Makefile.am (i_maxloc1_c): Readd generated/maxloc1_4_i8.c, generated/maxloc1_8_i8.c, generated/maxloc1_16_i8.c, generated/maxloc1_4_i16.c, generated/maxloc1_8_i16.c. Move generated/maxloc1_16_i16.c entry earlier in the list. * Makefile.in: Regenerated. 2025-04-22 Andre Vehreschild * caf/libcaf.h: Add mapping mode to coarray's register. * caf/single.c (_gfortran_caf_register): Create a token sharing another token's memory. (check_team): Check team parameters to coindexed expressions are valid. 2025-04-22 Andre Vehreschild * caf/libcaf.h (_gfortran_caf_num_images): Correct prototype. * caf/single.c (_gfortran_caf_num_images): Default implementation. 2025-04-22 Andre Vehreschild PR fortran/87326 * caf/libcaf.h (_gfortran_caf_this_image): Correct prototype. * caf/single.c (struct caf_single_team): Add new_index of image. (_gfortran_caf_this_image): Return the image index in the given team. (_gfortran_caf_form_team): Set new_index in team structure. 2025-04-22 Andre Vehreschild PR fortran/88154 PR fortran/88960 PR fortran/97210 PR fortran/103001 * caf/libcaf.h: Add constants for get_team's level argument and update stat values for failed images. (_gfortran_caf_team_number): Add prototype. (_gfortran_caf_get_team): Same. * caf/single.c (_gfortran_caf_team_number): Get the given team's team number. (_gfortran_caf_get_team): Get the current team or the team given by level when the argument is present. 2025-04-22 Andre Vehreschild PR fortran/87326 PR fortran/87556 PR fortran/88254 PR fortran/103796 * caf/libcaf.h: Remove commented block. (_gfortran_caf_form_team): Allow for all relevant arguments. (_gfortran_caf_change_team): Same. (_gfortran_caf_end_team): Same. (_gfortran_caf_sync_team): Same. * caf/single.c (struct caf_single_team): Team handling structures. (_gfortran_caf_init): Initialize initial team. (free_team_list): Free all teams and the memory they hold. (_gfortran_caf_finalize): Free initial and sibling teams. (_gfortran_caf_register): Add memory registered to current team. (_gfortran_caf_deregister): Unregister memory from current team. (_gfortran_caf_is_present_on_remote): Check token's memptr for llocation. May have been deallocated by an end team. (_gfortran_caf_form_team): Push a new team stub to the list. (_gfortran_caf_change_team): Push a formed team on top of the ctive teams stack. (_gfortran_caf_end_team): End the active team, free all memory allocated during its livespan. (_gfortran_caf_sync_team): Take stat and errmsg into account. 2025-04-22 Andre Vehreschild PR fortran/87939 * caf/single.c (_gfortran_caf_lock): Correct stat value, if lock is already locked by current image. (_gfortran_caf_unlock): Correct stat value, if lock is not locked. 2025-04-13 Jerry DeLisle PR libfortran/119502 * io/close.c (st_close): Issue an error and avoid calling close_share when there is no stream assigned. * io/open.c (st_open): If there is no stream assigned to the unit, unlock the unit and issue an error. 2025-04-09 Paul Thomas and Harald Anlauf PR libfortran/119460 * intrinsics/reduce.c (reduce): Correct error message about mismatch between dim and the rank of array. Output the values of both. Correct the evaluation of the result stride and extent. (reduce_scalar): The front end treats the result as an allocatable so eliminate memcpy and free. Return the base-addr of the local descriptor. (reduce_c): Correct the type of the string lengths. (reduce_scalar_c): Correct the type of the string lengths.Test to see if 'res' is allocated. If not then return the base_addr of the local descriptor. 2025-04-07 Lulu Cheng PR target/119408 * acinclude.m4: When checking for __float128 support, determine whether the current architecture is LoongArch. If so, return false. * configure: Regenerate. 2025-03-22 Hans-Peter Nilsson * intrinsics/reduce.c (reduce_scalar_c): Correct type of parameter DIM. 2025-03-21 Paul Thomas PR libfortran/85836 * Makefile.am : Add reduce.c * Makefile.in : Regenerated * gfortran.map : Add _gfortran_reduce, _gfortran_reduce_scalar, _gfortran_reduce_c and _gfortran_reduce_scalar_c to the list. * intrinsics/reduce.c (reduce, reduce_scalar, reduce_c, reduce_scalar_c): New functions and prototypes 2025-02-27 Thomas Schwinge PR target/107635 * config/t-nvptx: New. * configure.host [nvptx] (tmake_file): Add it. 2025-02-21 Andre Vehreschild PR fortran/107635 * caf/single.c: Replace alloca with __builtin_alloca. 2025-02-20 Andre Vehreschild * caf/libcaf.h (_gfortran_caf_get): Removed because deprecated. (_gfortran_caf_send): Same. (_gfortran_caf_sendget): Same. (_gfortran_caf_send_by_ref): Same. * caf/single.c (assign_char4_from_char1): Same. (assign_char1_from_char4): Same. (convert_type): Same. (defined): Same. (_gfortran_caf_get): Same. (_gfortran_caf_send): Same. (_gfortran_caf_sendget): Same. (copy_data): Same. (get_for_ref): Same. (_gfortran_caf_get_by_ref): Same. (send_by_ref): Same. (_gfortran_caf_send_by_ref): Same. (_gfortran_caf_sendget_by_ref): Same. 2025-02-20 Andre Vehreschild * caf/libcaf.h: Add prototype for transfer_between_remotes. * caf/single.c: Implement transfer_between_remotes. 2025-02-20 Andre Vehreschild * caf/libcaf.h: Add/Correct prototypes for caf_get_from_remote, caf_send_to_remote. * caf/single.c (struct accessor_hash_t): Rename accessor_t to getter_t. (_gfortran_caf_register_accessor): Use new name of getter_t. (_gfortran_caf_send_to_remote): New function for sending data to coarray on a remote image. 2025-02-20 Andre Vehreschild * caf/libcaf.h (_gfortran_caf_is_present_on_remote): Add new function. (_gfortran_caf_is_present): Remove deprecated one. * caf/single.c (struct accessor_hash_t): Add function ptr access for remote side call. (_gfortran_caf_is_present_on_remote): Added. (_gfortran_caf_is_present): Removed. 2025-02-20 Andre Vehreschild * caf/libcaf.h (_gfortran_caf_register_accessor): Reflect changed parameter order. * caf/single.c (struct accessor_hash_t): Same. (_gfortran_caf_register_accessor): Call accessor using a token for accessing arrays with a descriptor on the source side. 2025-02-20 Andre Vehreschild * caf/libcaf.h (_gfortran_caf_get_by_ref): Remove from ABI. This function is replaced by caf_get_from_remote (). (_gfortran_caf_get_remote_function_index): Use better name. * caf/single.c (_gfortran_caf_finalize): Free internal data. (_gfortran_caf_get_by_ref): Remove from public interface, but keep it, because it is still used by sendget (). 2025-02-20 Andre Vehreschild * caf/single.c (_gfortran_caf_finalize): Free memory preventing leaks. (_gfortran_caf_get_by_ct): Fix constness. * caf/libcaf.h (_gfortran_caf_register_accessor): Fix constness. 2025-02-06 Jerry DeLisle PR libfortran/114618 * io/transfer.c (formatted_transfer_scalar_write): Change name of vriable 'pos' to 'tab_pos' to improve clarity. Add new variable next_pos when calculating the maximum position. Update the calculation of pending spaces. 2025-02-04 Thomas Koenig * Makefile.am: Add files for unsigned exponentiation. * Makefile.in: Regenerate. * gfortran.map: Add functions for unsigned exponentiation. * generated/pow_m16_m1.c: New file. * generated/pow_m16_m16.c: New file. * generated/pow_m16_m2.c: New file. * generated/pow_m16_m4.c: New file. * generated/pow_m16_m8.c: New file. * generated/pow_m1_m1.c: New file. * generated/pow_m1_m16.c: New file. * generated/pow_m1_m2.c: New file. * generated/pow_m1_m4.c: New file. * generated/pow_m1_m8.c: New file. * generated/pow_m2_m1.c: New file. * generated/pow_m2_m16.c: New file. * generated/pow_m2_m2.c: New file. * generated/pow_m2_m4.c: New file. * generated/pow_m2_m8.c: New file. * generated/pow_m4_m1.c: New file. * generated/pow_m4_m16.c: New file. * generated/pow_m4_m2.c: New file. * generated/pow_m4_m4.c: New file. * generated/pow_m4_m8.c: New file. * generated/pow_m8_m1.c: New file. * generated/pow_m8_m16.c: New file. * generated/pow_m8_m2.c: New file. * generated/pow_m8_m4.c: New file. * generated/pow_m8_m8.c: New file. * m4/powu.m4: New file. 2025-01-24 Jerry DeLisle PR libfortran/118571 * io/write.c (write_utf8_char4): Adjust the src_len to the format width w_len when greater than zero. 2025-01-17 Harald Anlauf PR libfortran/118536 * io/transfer.c (formatted_transfer_scalar_write): Handle UNSIGNED in G formatting. 2025-01-16 Harald Anlauf PR libfortran/118406 * runtime/string.c (gfc_itoa): Handle unsigned integers larger than (10^19 * 2^64). Copyright (C) 2025 Free Software Foundation, Inc. Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved.