changeset 1171:3fcbbd7f7873

[Issue 396] New: aliased identifier in asm blocks cause compiler segment faults Thomas Kuehne <thomas-dloop@kuehne.cn> 2006-10-03 news:bug-396-3@http.d.puremagic.com/issues/
author thomask
date Wed, 04 Oct 2006 06:28:17 +0000
parents 851d63db41cb
children deaf29e6f037
files run/a/alias_38_A.d run/a/alias_38_B.d run/a/alias_38_C.d
diffstat 3 files changed, 109 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/a/alias_38_A.d	Wed Oct 04 06:28:17 2006 +0000
@@ -0,0 +1,37 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+// @author@	Thomas Kuehne <thomas-dloop@kuehne.cn>
+// @date@	2006-10-03
+// @uri@	news:bug-396-3@http.d.puremagic.com/issues/
+// @desc@	[Issue 396] New: aliased identifier in asm blocks cause compiler segment faults
+
+module dstress.run.a.alias_38_A;
+
+version(D_InlineAsm_X86){
+	version = runTest;
+}else version(D_InlineAsm_X86_64){
+	version = runTest;
+}
+
+version(runTest){
+	int main(){
+		int x = 1;
+
+		alias x y;
+
+		asm{
+			inc y;
+		}
+
+		if(y != 2){
+			assert(0);
+		}
+
+		return 0;
+	}
+}else{
+	pragma(msg, "DSTRESS{XFAIL}: no inline ASM support");
+	static assert(0);
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/a/alias_38_B.d	Wed Oct 04 06:28:17 2006 +0000
@@ -0,0 +1,35 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+// @author@	Thomas Kuehne <thomas-dloop@kuehne.cn>
+// @date@	2006-10-03
+// @uri@	news:bug-396-3@http.d.puremagic.com/issues/
+// @desc@	[Issue 396] New: aliased identifier in asm blocks cause compiler segment faults
+
+module dstress.run.a.alias_38_B;
+
+version(D_InlineAsm_X86){
+	version = runTest;
+}else version(D_InlineAsm_X86_64){
+	version = runTest;
+}
+
+version(runTest){
+	int main(){
+		int x = 1;
+
+		alias x y;
+
+		y++;
+
+		if(y != 2){
+			assert(0);
+		}
+
+		return 0;
+	}
+}else{
+	pragma(msg, "DSTRESS{XFAIL}: no inline ASM support");
+	static assert(0);
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/run/a/alias_38_C.d	Wed Oct 04 06:28:17 2006 +0000
@@ -0,0 +1,37 @@
+// $HeadURL$
+// $Date$
+// $Author$
+
+// @author@	Thomas Kuehne <thomas-dloop@kuehne.cn>
+// @date@	2006-10-03
+// @uri@	news:bug-396-3@http.d.puremagic.com/issues/
+// @desc@	[Issue 396] New: aliased identifier in asm blocks cause compiler segment faults
+
+module dstress.run.a.alias_38_C;
+
+version(D_InlineAsm_X86){
+	version = runTest;
+}else version(D_InlineAsm_X86_64){
+	version = runTest;
+}
+
+version(runTest){
+	int main(){
+		int x = 1;
+
+		alias x y;
+
+		asm{
+			inc x;
+		}
+
+		if(y != 2){
+			assert(0);
+		}
+
+		return 0;
+	}
+}else{
+	pragma(msg, "DSTRESS{XFAIL}: no inline ASM support");
+	static assert(0);
+}