Commit ceaba33e by Mike Stump Committed by Mike Stump

udlit-raw-op.C: Don't use CRLF endings.

	* g++.dg/cpp0x/udlit-raw-op.C: Don't use CRLF endings.
	* gcc.dg/tree-ssa/vrp59.c: Likewise.

From-SVN: r186259
parent d0779896
2012-04-09 Mike Stump <mikestump@comcast.net> 2012-04-09 Mike Stump <mikestump@comcast.net>
* g++.dg/cpp0x/udlit-raw-op.C: Don't use CRLF endings.
* gcc.dg/tree-ssa/vrp59.c: Likewise.
* gcc.dg/dll-8.c: Remove execute permissions. * gcc.dg/dll-8.c: Remove execute permissions.
* g++.dg/ext/dllexport5.C: Likewise. * g++.dg/ext/dllexport5.C: Likewise.
......
// { dg-do run } // { dg-do run }
// { dg-options "-std=c++0x" } // { dg-options "-std=c++0x" }
#include <cassert> #include <cassert>
#include <cstring> #include <cstring>
int int
operator"" _raw_umber(const char * str) operator"" _raw_umber(const char * str)
{ {
return strlen(str); return strlen(str);
} }
int int
main() main()
{ {
int i = 0123012301230123012301230123012301230123012301230123012301230123_raw_umber; int i = 0123012301230123012301230123012301230123012301230123012301230123_raw_umber;
assert( i == 64 ); assert( i == 64 );
int j = 90123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789_raw_umber; int j = 90123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789_raw_umber;
assert( j == 101 ); assert( j == 101 );
} }
/* { dg-do compile } */ /* { dg-do compile } */
/* { dg-options "-O2 -fno-tree-ccp -fdump-tree-vrp1" } */ /* { dg-options "-O2 -fno-tree-ccp -fdump-tree-vrp1" } */
int f(int x) int f(int x)
{ {
if (x >= 0 && x <= 3) if (x >= 0 && x <= 3)
{ {
x = x ^ 3; x = x ^ 3;
x = x & 3; x = x & 3;
} }
return x; return x;
} }
int g(int x) int g(int x)
{ {
if (x >= 0 && x <= 3) if (x >= 0 && x <= 3)
{ {
x = x ^ 2; x = x ^ 2;
x = x & 3; x = x & 3;
} }
return x; return x;
} }
int h(int x) int h(int x)
{ {
if (x >= 0 && x <= 3) if (x >= 0 && x <= 3)
{ {
x = x ^ 1; x = x ^ 1;
x = x & 3; x = x & 3;
} }
return x; return x;
} }
/* { dg-final { scan-tree-dump-not " & 3;" "vrp1" } } */ /* { dg-final { scan-tree-dump-not " & 3;" "vrp1" } } */
/* { dg-final { cleanup-tree-dump "vrp1" } } */ /* { dg-final { cleanup-tree-dump "vrp1" } } */
/* { dg-do compile } */ /* { dg-do compile } */
/* { dg-options "-O2 -fno-tree-ccp -fno-tree-dominator-opts -fdump-tree-vrp1" } */ /* { dg-options "-O2 -fno-tree-ccp -fno-tree-dominator-opts -fdump-tree-vrp1" } */
int foo (int x, int b) int foo (int x, int b)
{ {
int cst; int cst;
if (b) if (b)
cst = -__INT_MAX__ - 1; cst = -__INT_MAX__ - 1;
else else
cst = -__INT_MAX__; cst = -__INT_MAX__;
x = x | cst; x = x | cst;
if (x >= 0) if (x >= 0)
return 12345; return 12345;
return x; return x;
} }
int bar (int x, int b) int bar (int x, int b)
{ {
int cst; int cst;
if (b) if (b)
cst = __INT_MAX__; cst = __INT_MAX__;
else else
cst = __INT_MAX__ - 1; cst = __INT_MAX__ - 1;
x = x & cst; x = x & cst;
if (x < 0) if (x < 0)
return 12345; return 12345;
return x; return x;
} }
/* { dg-final { scan-tree-dump-not "12345" "vrp1" } } */ /* { dg-final { scan-tree-dump-not "12345" "vrp1" } } */
/* { dg-final { cleanup-tree-dump "vrp1" } } */ /* { dg-final { cleanup-tree-dump "vrp1" } } */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment