xref: /llvm-project/clang/test/CodeGenCXX/pr54845.cpp (revision 93a8225da1f983cccb3e4b5e762369121aaa7dd5)
1 // RUN: %clang_cc1 -triple i686-linux-gnu -emit-llvm %s -o - | FileCheck %s
2 // https://github.com/llvm/llvm-project/issues/54845
3 
4 void *operator new(unsigned int, void *);
5 
test(double * d)6 void test(double *d) {
7   // This store used to have an alignment of 8, which was incorrect as
8   // the i386 psABI only guarantees a 4-byte alignment for doubles.
9 
10   // CHECK: store double 0.000000e+00, {{.*}}, align 4
11   new (d) double(0);
12 }
13