1  /* Trivially making sure IPA-SRA does not introduce segfaults where they should
       2     not be.  */
       3  
       4  struct bovid
       5  {
       6    float red;
       7    int green;
       8    void *blue;
       9  };
      10  
      11  static int
      12  __attribute__((noinline))
      13  ox (int fail, struct bovid *cow)
      14  {
      15    int r;
      16    if (fail)
      17      r = cow->red;
      18    else
      19      r = 0;
      20    return r;
      21  }
      22  
      23  int main (int argc, char *argv[])
      24  {
      25    int r;
      26  
      27    r = ox ((argc > 2000), (void *) 0);
      28    return r;
      29  }