This patch adds appropriate .type for jump table data.
Applied as obvious.

Johann

--

AVR: Set .type of jump table label.

gcc/
* config/avr/avr.cc (avr_output_addr_vec) <labl>: Asm out its .type.

diff --git a/gcc/config/avr/avr.cc b/gcc/config/avr/avr.cc
index 94684468de3..1fb59b624de 100644
--- a/gcc/config/avr/avr.cc
+++ b/gcc/config/avr/avr.cc
@@ -14418,6 +14418,13 @@ avr_output_addr_vec (rtx_insn *labl, rtx table)
   // Output the label that precedes the table.

   ASM_OUTPUT_ALIGN (stream, 1);
+
+  char s_labl[40];
+  targetm.asm_out.generate_internal_label (s_labl, "L",
+                                          CODE_LABEL_NUMBER (labl));
+  ASM_OUTPUT_TYPE_DIRECTIVE (stream, s_labl,
+                            AVR_HAVE_JMP_CALL ? "object" : "function");
+
   targetm.asm_out.internal_label (stream, "L", CODE_LABEL_NUMBER (labl));

   // Output the table's content.

Reply via email to