public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [pph] Add testcase for shared streamed data (issue4532094)
@ 2011-05-27 19:26 Diego Novillo
  0 siblings, 0 replies; only message in thread
From: Diego Novillo @ 2011-05-27 19:26 UTC (permalink / raw)
  To: reply, crowl, gcc-patches

This is the test I was referring to in
http://gcc.gnu.org/ml/gcc-patches/2011-05/msg02184.html

The test, taken from the C testsuite, creates hundreds of thousands of
shared bindings.  Without sharing support, the streamer was trying to
instantiate new objects, and ICEing eventually when the stack was
blown.

I have several other C test cases that are currently causing problem
(or used to be a problem).  I'll keep adding some representative tests
as I fix them.


Diego.


	* g++.dg/pph/c1limits-externalid.cc: New.
	* g++.dg/pph/c1limits-externalid.h: New.

diff --git a/gcc/testsuite/g++.dg/pph/c1limits-externalid.cc b/gcc/testsuite/g++.dg/pph/c1limits-externalid.cc
new file mode 100644
index 0000000..8b5039c
--- /dev/null
+++ b/gcc/testsuite/g++.dg/pph/c1limits-externalid.cc
@@ -0,0 +1 @@
+#include "c1limits-externalid.h"
diff --git a/gcc/testsuite/g++.dg/pph/c1limits-externalid.h b/gcc/testsuite/g++.dg/pph/c1limits-externalid.h
new file mode 100644
index 0000000..fbfa767
--- /dev/null
+++ b/gcc/testsuite/g++.dg/pph/c1limits-externalid.h
@@ -0,0 +1,18 @@
+#ifndef __PPH_GUARD_H
+#define __PPH_GUARD_H
+#define LIM1(x) x##0; x##1; x##2; x##3; x##4; x##5; x##6; x##7; x##8; x##9;
+#define LIM2(x) LIM1(x##0) LIM1(x##1) LIM1(x##2) LIM1(x##3) LIM1(x##4) \
+		LIM1(x##5) LIM1(x##6) LIM1(x##7) LIM1(x##8) LIM1(x##9)
+#define LIM3(x) LIM2(x##0) LIM2(x##1) LIM2(x##2) LIM2(x##3) LIM2(x##4) \
+		LIM2(x##5) LIM2(x##6) LIM2(x##7) LIM2(x##8) LIM2(x##9)
+#define LIM4(x) LIM3(x##0) LIM3(x##1) LIM3(x##2) LIM3(x##3) LIM3(x##4) \
+		LIM3(x##5) LIM3(x##6) LIM3(x##7) LIM3(x##8) LIM3(x##9)
+#define LIM5(x) LIM4(x##0) LIM4(x##1) LIM4(x##2) LIM4(x##3) LIM4(x##4) \
+		LIM4(x##5) LIM4(x##6) LIM4(x##7) LIM4(x##8) LIM4(x##9)
+#define LIM6(x) LIM5(x##0) LIM5(x##1) LIM5(x##2) LIM5(x##3) LIM5(x##4) \
+		LIM5(x##5) LIM5(x##6) LIM5(x##7) LIM5(x##8) LIM5(x##9)
+#define LIM7(x) LIM6(x##0) LIM6(x##1) LIM6(x##2) LIM6(x##3) LIM6(x##4) \
+		LIM6(x##5) LIM6(x##6) LIM6(x##7) LIM6(x##8) LIM6(x##9)
+
+LIM5(char t)
+#endif

--
This patch is available for review at http://codereview.appspot.com/4532094

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-05-27 18:42 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-27 19:26 [pph] Add testcase for shared streamed data (issue4532094) Diego Novillo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).