CVS-19981231: PATCH for incorrect label refs on i586-linux
Jeffrey A Law
law@cygnus.com
Fri Jan 1 10:55:00 GMT 1999
Try this patch. It's really kind of silly not to use the normal label
mechanisms anyway...
Index: i386.md
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/config/i386/i386.md,v
retrieving revision 1.44
diff -c -3 -p -r1.44 i386.md
*** i386.md 1998/12/30 22:45:16 1.44
--- i386.md 1999/01/01 18:48:19
*************** byte_xor_operation:
*** 4687,4694 ****
""
"*
{
! rtx xops[4], low[1], high[1];
! static int ashldi_label_number;
CC_STATUS_INIT;
--- 4687,4693 ----
""
"*
{
! rtx xops[5], low[1], high[1];
CC_STATUS_INIT;
*************** byte_xor_operation:
*** 4697,4713 ****
xops[1] = GEN_INT (32);
xops[2] = low[0];
xops[3] = high[0];
output_asm_insn (AS3_SHIFT_DOUBLE (shld%L3,%0,%2,%3), xops);
output_asm_insn (AS2 (sal%L2,%0,%2), xops);
output_asm_insn (AS2 (test%B0,%1,%b0), xops);
! fputs (\"\\tje \", asm_out_file);
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"LASHLDI\", ashldi_label_number);
! fputs (\"\\n\", asm_out_file);
output_asm_insn (AS2 (mov%L3,%2,%3), xops); /* Fast shift by 32 */
output_asm_insn (AS2 (xor%L2,%2,%2), xops);
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"LASHLDI\", ashldi_label_number);
! ashldi_label_number++;
RET;
}")
--- 4696,4711 ----
xops[1] = GEN_INT (32);
xops[2] = low[0];
xops[3] = high[0];
+ xops[4] = gen_label_rtx ();
output_asm_insn (AS3_SHIFT_DOUBLE (shld%L3,%0,%2,%3), xops);
output_asm_insn (AS2 (sal%L2,%0,%2), xops);
output_asm_insn (AS2 (test%B0,%1,%b0), xops);
! output_asm_insn (AS1 (je,%X4), xops);
output_asm_insn (AS2 (mov%L3,%2,%3), xops); /* Fast shift by 32 */
output_asm_insn (AS2 (xor%L2,%2,%2), xops);
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"L\",
! CODE_LABEL_NUMBER (xops[4]));
RET;
}")
*************** byte_xor_operation:
*** 4877,4884 ****
""
"*
{
! rtx xops[4], low[1], high[1];
! static int ashrdi_label_number;
CC_STATUS_INIT;
--- 4875,4881 ----
""
"*
{
! rtx xops[5], low[1], high[1];
CC_STATUS_INIT;
*************** byte_xor_operation:
*** 4887,4904 ****
xops[1] = GEN_INT (32);
xops[2] = low[0];
xops[3] = high[0];
output_asm_insn (AS3_SHIFT_DOUBLE (shrd%L2,%0,%3,%2), xops);
output_asm_insn (AS2 (sar%L3,%0,%3), xops);
output_asm_insn (AS2 (test%B0,%1,%b0), xops);
! fputs (\"\\tje \", asm_out_file);
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"LASHRDI\", ashrdi_label_number);
! fputs (\"\\n\", asm_out_file);
xops[1] = GEN_INT (31);
output_asm_insn (AS2 (mov%L2,%3,%2), xops);
output_asm_insn (AS2 (sar%L3,%1,%3), xops); /* shift by 32 */
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"LASHRDI\", ashrdi_label_number);
! ashrdi_label_number++;
RET;
}")
--- 4884,4900 ----
xops[1] = GEN_INT (32);
xops[2] = low[0];
xops[3] = high[0];
+ xops[4] = gen_label_rtx ();
output_asm_insn (AS3_SHIFT_DOUBLE (shrd%L2,%0,%3,%2), xops);
output_asm_insn (AS2 (sar%L3,%0,%3), xops);
output_asm_insn (AS2 (test%B0,%1,%b0), xops);
! output_asm_insn (AS1 (je,%X4), xops);
xops[1] = GEN_INT (31);
output_asm_insn (AS2 (mov%L2,%3,%2), xops);
output_asm_insn (AS2 (sar%L3,%1,%3), xops); /* shift by 32 */
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"L\",
! CODE_LABEL_NUMBER (xops[4]));
RET;
}")
*************** byte_xor_operation:
*** 5043,5050 ****
""
"*
{
! rtx xops[4], low[1], high[1];
! static int lshrdi_label_number;
CC_STATUS_INIT;
--- 5039,5045 ----
""
"*
{
! rtx xops[5], low[1], high[1];
CC_STATUS_INIT;
*************** byte_xor_operation:
*** 5053,5069 ****
xops[1] = GEN_INT (32);
xops[2] = low[0];
xops[3] = high[0];
output_asm_insn (AS3_SHIFT_DOUBLE (shrd%L2,%0,%3,%2), xops);
output_asm_insn (AS2 (shr%L3,%0,%3), xops);
output_asm_insn (AS2 (test%B0,%1,%b0), xops);
! fputs (\"\\tje \", asm_out_file);
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"LLSHRDI\", lshrdi_label_number);
! fputs (\"\\n\", asm_out_file);
output_asm_insn (AS2 (mov%L2,%3,%2), xops); /* Fast shift by 32 */
output_asm_insn (AS2 (xor%L3,%3,%3), xops);
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"LLSHRDI\", lshrdi_label_number);
! lshrdi_label_number++;
RET;
}")
--- 5048,5063 ----
xops[1] = GEN_INT (32);
xops[2] = low[0];
xops[3] = high[0];
+ xops[4] = gen_label_rtx ();
output_asm_insn (AS3_SHIFT_DOUBLE (shrd%L2,%0,%3,%2), xops);
output_asm_insn (AS2 (shr%L3,%0,%3), xops);
output_asm_insn (AS2 (test%B0,%1,%b0), xops);
! output_asm_insn (AS1 (je,%X4), xops);
output_asm_insn (AS2 (mov%L2,%3,%2), xops); /* Fast shift by 32 */
output_asm_insn (AS2 (xor%L3,%3,%3), xops);
! ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, \"L\",
! CODE_LABEL_NUMBER (xops[4]));
RET;
}")
More information about the Gcc-patches
mailing list