re PR sanitizer/61095 (miscompile: tsan is broken in gcc trunk, works in 4.9)
gcc/testsuite/ PR tree-optimization/61095 * gcc.dg/torture/pr61095.c: New test. From-SVN: r210203
This commit is contained in:
parent
ca49b74e1c
commit
c7ad35388d
2 changed files with 28 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2014-05-08 Richard Sandiford <rdsandiford@googlemail.com>
|
||||||
|
|
||||||
|
PR tree-optimization/61095
|
||||||
|
* gcc.dg/torture/pr61095.c: New test.
|
||||||
|
|
||||||
2014-05-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
|
2014-05-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
|
||||||
|
|
||||||
PR middle-end/39246
|
PR middle-end/39246
|
||||||
|
|
23
gcc/testsuite/gcc.dg/torture/pr61095.c
Normal file
23
gcc/testsuite/gcc.dg/torture/pr61095.c
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target lp64 } */
|
||||||
|
|
||||||
|
extern void __attribute__ ((noreturn)) abort (void);
|
||||||
|
|
||||||
|
int __attribute__ ((noinline, noclone))
|
||||||
|
foo (unsigned long addr) {
|
||||||
|
unsigned long *p = (unsigned long*)((addr & 0xffff83fffffffff8UL) * 4);
|
||||||
|
unsigned long xxx = (unsigned long)(p + 1);
|
||||||
|
return xxx >= 0x3c000000000UL;
|
||||||
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
main (void)
|
||||||
|
{
|
||||||
|
if (foo (0))
|
||||||
|
abort ();
|
||||||
|
if (foo (0x7c0000000000UL))
|
||||||
|
abort ();
|
||||||
|
if (!foo (0xfc0000000000UL))
|
||||||
|
abort ();
|
||||||
|
return 0;
|
||||||
|
}
|
Loading…
Add table
Reference in a new issue