diff options
author | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2010-11-10 12:34:24 +0000 |
---|---|---|
committer | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2010-11-10 12:34:24 +0000 |
commit | ec604c3c577443a3bbc436d0cbcc06b6b67f3851 (patch) | |
tree | 2dfbb67b9cc2e3425926b401dfb295ddbc67555f /test/regression/struct9.c | |
parent | e884946c8788db4eb791fa93761d487b9de13ae4 (diff) | |
download | compcert-ec604c3c577443a3bbc436d0cbcc06b6b67f3851.tar.gz compcert-ec604c3c577443a3bbc436d0cbcc06b6b67f3851.zip |
In StructAssign: be careful not to duplicate accesses to a volatile variable.
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1551 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'test/regression/struct9.c')
-rw-r--r-- | test/regression/struct9.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/regression/struct9.c b/test/regression/struct9.c new file mode 100644 index 00000000..fae137ce --- /dev/null +++ b/test/regression/struct9.c @@ -0,0 +1,13 @@ +struct S1 { + unsigned char f0; + short f1; +}; + +struct S1 g_77 = {0x73,9}; +struct S1 * volatile g_85 = &g_77; +struct S1 g_204 = {0xAD,0x9086}; + +void func_1(void) +{ + *g_85 = g_204; +} |