Skip to content

Commit 2d3451e

Browse files
jpoimboeingomolnar
authored andcommitted
objtool: Simplify .annotate_insn code generation output some more
Remove the superfluous section name quotes, and combine the longs into a single command. Before: 911: .pushsection ".discard.annotate_insn", "M", @progbits, 8; .long 911b - .; .long 2; .popsection After: 911: .pushsection .discard.annotate_insn, "M", @progbits, 8; .long 911b - ., 2; .popsection No change in functionality. Suggested-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> Link: https://patch.msgid.link/hpsfcihgqmhcdrg7pop7z73ptymakgjq7qlxrawrjxilosk43l@xikqif3ievj4
1 parent 799647d commit 2d3451e

1 file changed

Lines changed: 6 additions & 7 deletions

File tree

include/linux/annotate.h

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,33 +8,32 @@
88

99
#define __ASM_ANNOTATE(section, label, type) \
1010
.pushsection section, "M", @progbits, 8; \
11-
.long label - .; \
12-
.long type; \
11+
.long label - ., type; \
1312
.popsection
1413

1514
#ifndef __ASSEMBLY__
1615

1716
#define ASM_ANNOTATE_LABEL(label, type) \
18-
__stringify(__ASM_ANNOTATE(".discard.annotate_insn", label, type))
17+
__stringify(__ASM_ANNOTATE(.discard.annotate_insn, label, type))
1918

2019
#define ASM_ANNOTATE(type) \
2120
"911: " \
22-
__stringify(__ASM_ANNOTATE(".discard.annotate_insn", 911b, type))
21+
__stringify(__ASM_ANNOTATE(.discard.annotate_insn, 911b, type))
2322

2423
#define ASM_ANNOTATE_DATA(type) \
2524
"912: " \
26-
__stringify(__ASM_ANNOTATE(".discard.annotate_data", 912b, type))
25+
__stringify(__ASM_ANNOTATE(.discard.annotate_data, 912b, type))
2726

2827
#else /* __ASSEMBLY__ */
2928

3029
.macro ANNOTATE type
3130
.Lhere_\@:
32-
__ASM_ANNOTATE(".discard.annotate_insn", .Lhere_\@, \type)
31+
__ASM_ANNOTATE(.discard.annotate_insn, .Lhere_\@, \type)
3332
.endm
3433

3534
.macro ANNOTATE_DATA type
3635
.Lhere_\@:
37-
__ASM_ANNOTATE(".discard.annotate_data", .Lhere_\@, \type)
36+
__ASM_ANNOTATE(.discard.annotate_data, .Lhere_\@, \type)
3837
.endm
3938

4039
#endif /* __ASSEMBLY__ */

0 commit comments

Comments
 (0)