view gcc/testsuite/gcc.c-torture/compile/20071102-1.c @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
line wrap: on
line source

/* PR rtl-optimization/28062 */
/* Original testcase by Martin Michlmayr <tbm@cyrius.com> */
/* C testcase by Andrew Pinski <pinskia@gcc.gnu.org> */

struct _NSPoint
{
  float x;
  float y;
};

typedef struct _NSPoint NSPoint;

static inline NSPoint
NSMakePoint (float x, float y)
{
  NSPoint point;
  point.x = x;
  point.y = y;
  return point;
}

static inline NSPoint
RelativePoint (NSPoint point, NSPoint refPoint)
{
  return NSMakePoint (refPoint.x + point.x, refPoint.y + point.y);
}

NSPoint g(NSPoint refPoint)
{
  float pointA, pointB;
  return RelativePoint (NSMakePoint (0, pointA), refPoint);
}