X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=libgfortran%2Fgenerated%2Fspread_r4.c;h=56fc4ccfaf60aad67f60407be5e68d772940e406;hb=4d8cd3a26294ce35abb17668eac2b6c38dd23bd0;hp=fac0900cbb442fc0dca724c84aa741e49f0eb1d1;hpb=c944d49b3bd3667c65c299afd3b1d756084203f4;p=platform%2Fupstream%2Fgcc48.git diff --git a/libgfortran/generated/spread_r4.c b/libgfortran/generated/spread_r4.c index fac0900..56fc4cc 100644 --- a/libgfortran/generated/spread_r4.c +++ b/libgfortran/generated/spread_r4.c @@ -1,9 +1,9 @@ /* Special implementation of the SPREAD intrinsic - Copyright 2008, 2009 Free Software Foundation, Inc. + Copyright (C) 2008-2013 Free Software Foundation, Inc. Contributed by Thomas Koenig , based on spread_generic.c written by Paul Brook -This file is part of the GNU Fortran 95 runtime library (libgfortran). +This file is part of the GNU Fortran runtime library (libgfortran). Libgfortran is free software; you can redistribute it and/or modify it under the terms of the GNU General Public @@ -67,7 +67,7 @@ spread_r4 (gfc_array_r4 *ret, const gfc_array_r4 *source, ncopies = pncopies; - if (ret->data == NULL) + if (ret->base_addr == NULL) { size_t ub, stride; @@ -101,8 +101,8 @@ spread_r4 (gfc_array_r4 *ret, const gfc_array_r4 *source, } ret->offset = 0; - /* internal_malloc_size allocates a single byte for zero size. */ - ret->data = internal_malloc_size (rs * sizeof(GFC_REAL_4)); + /* xmalloc allocates a single byte for zero size. */ + ret->base_addr = xmalloc (rs * sizeof(GFC_REAL_4)); if (rs <= 0) return; } @@ -181,8 +181,8 @@ spread_r4 (gfc_array_r4 *ret, const gfc_array_r4 *source, } sstride0 = sstride[0]; rstride0 = rstride[0]; - rptr = ret->data; - sptr = source->data; + rptr = ret->base_addr; + sptr = source->base_addr; while (sptr) { @@ -242,9 +242,9 @@ spread_scalar_r4 (gfc_array_r4 *ret, const GFC_REAL_4 *source, if (along > 1) runtime_error ("dim outside of rank in spread()"); - if (ret->data == NULL) + if (ret->base_addr == NULL) { - ret->data = internal_malloc_size (ncopies * sizeof (GFC_REAL_4)); + ret->base_addr = xmalloc (ncopies * sizeof (GFC_REAL_4)); ret->offset = 0; GFC_DIMENSION_SET(ret->dim[0], 0, ncopies - 1, 1); } @@ -255,7 +255,7 @@ spread_scalar_r4 (gfc_array_r4 *ret, const GFC_REAL_4 *source, runtime_error ("dim too large in spread()"); } - dest = ret->data; + dest = ret->base_addr; stride = GFC_DESCRIPTOR_STRIDE(ret,0); for (n = 0; n < ncopies; n++)