re PR middle-end/65074 (r220674 broke C++ PIEs)

PR middle-end/65074

 * g++.dg/opt/pr65074.C: New file.

From-SVN: r220817
This commit is contained in:
Jakub Jelinek 2015-02-19 16:48:50 +01:00 committed by Richard Henderson
parent 0ff5fade6a
commit 801050dc4c
2 changed files with 24 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2015-02-19 Jakub Jelinek <jakub@redhat.com>
PR middle-end/65074
* g++.dg/opt/pr65074.C: New file.
2015-02-19 Andrea Azzarone <azzaronea@gmail.com>
* g++.dg/cpp1y/udlit-char-template-vs-std-literal-operator.C

View File

@ -0,0 +1,19 @@
// PR middle-end/65074
// { dg-do link { target pie } }
// { dg-options "-pie -fpie -O2" }
#include <fstream>
using namespace std;
__attribute__((noinline, noclone)) void
foo (const char *fname)
{
ifstream f (fname);
}
int
main ()
{
foo ("foobar");
}