Hello.

On my system tcc kept producing different binaries of itself each run which made
doing bootstrap testing (as gcc does) impossible. The attached patch fixes
this.

Felix
--- tinycc-orig/tcc.c   2006-07-03 18:47:35.000000000 +0200
+++ tinycc/tcc.c        2006-07-04 20:00:28.000000000 +0200
@@ -4792,6 +4792,13 @@
             offset = (data_section->data_offset + align - 1) & -align;
             data_section->data_offset = offset;
             /* XXX: not portable yet */
+#ifdef __i386__
+            /* really not. long doubles are defined to be 96 bit wide by
+               the i386 ABI but the x87 only uses the first 80. The rest
+               is filled with garbage by now, so clear it before writing */
+            if(size == 12)
+                vtop->c.tab[2] &= 0xffff;
+#endif
             ptr = section_ptr_add(data_section, size);
             size = size >> 2;
             for(i=0;i<size;i++)
_______________________________________________
Tinycc-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/tinycc-devel

Reply via email to