brintos

brintos / llvm-project-archived public Read only

0
0
Text · 344 B · effc0a6 Raw
17 lines · c
1// RUN: %clang_cc1 %s -emit-llvm -O1 -o - | FileCheck %s2// The load here was getting lost because this code was close3// enough to the traditional (wrong) implementation of offsetof4// to confuse the gcc FE.  8629268.5 6struct foo {7  int x;8  int *y;9};10 11struct foo Foo[1];12 13int * bar(unsigned int ix) {14// CHECK: load15  return &Foo->y[ix];16}17