[mpich-devel] warning: returning 'uint32_t *' (aka 'unsigned int *') from a function with result type 'int *' converts between pointers to integer types with different sign
"Antonio J. Peña"
apenya at mcs.anl.gov
Mon Mar 9 19:58:06 CDT 2015
Hi Jeff,
Please also report compiler, compiler version, and MPICH version.
Best,
Toni
On 03/09/2015 07:53 PM, Jeff Hammond wrote:
> I know some of you like warning-clean builds...
>
> ../src/mpid/ch3/src/mpid_comm_get_all_failed_procs.c:20:14: warning:
> assigning to 'uint32_t *' (aka 'unsigned int *') from 'int *'
> converts between pointers to integer types with different sign
> [-Wpointer-sign]
> bitarray = (int *) MPIU_Malloc(sizeof(int) * bitarray_size);
> ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> ../src/mpid/ch3/src/mpid_comm_get_all_failed_procs.c:24:16: warning:
> returning 'uint32_t *' (aka 'unsigned int *') from a function
> with result type 'int *' converts between pointers to integer
> types with different sign [-Wpointer-sign]
> return bitarray;
> ^~~~~~~~
> ../src/mpid/ch3/src/mpid_comm_get_all_failed_procs.c:46:12: warning:
> returning 'uint32_t *' (aka 'unsigned int *') from a function
> with result type 'int *' converts between pointers to integer
> types with different sign [-Wpointer-sign]
> return bitarray;
> ^~~~~~~~
> ../src/mpid/ch3/src/mpid_comm_get_all_failed_procs.c:107:14: warning:
> assigning to 'uint32_t *' (aka 'unsigned int *') from
> 'int *' converts between pointers to integer types with
> different sign [-Wpointer-sign]
> bitarray = group_to_bitarray(local_fail, comm_ptr);
> ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 4 warnings generated.
>
> Best,
>
> Jeff
>
--
Antonio J. Peña
Postdoctoral Appointee
Mathematics and Computer Science Division
Argonne National Laboratory
9700 South Cass Avenue, Bldg. 240, Of. 3148
Argonne, IL 60439-4847
apenya at mcs.anl.gov
www.mcs.anl.gov/~apenya
More information about the devel
mailing list