From f96403b03dc6c35de1372c33976245c34e7c60b8 Mon Sep 17 00:00:00 2001 From: "Paul A. Clarke" Date: Fri, 7 Nov 2025 12:19:41 -0600 Subject: [PATCH] Fix missing Assembly section for instructions with no variables Remove conditional check that hides Assembly section when assembly field is empty. Now instructions like fence.i will properly show "Assembly:: fence.i" in the instruction appendix instead of omitting the section entirely. Co-authored-by: Afonso Oliveira Co-authored-by: Paul A. Clarke Signed-off-by: Paul A. Clarke --- .../all_instructions.golden.adoc | 75 +++++++++++++++++++ .../templates/instructions.adoc.erb | 4 +- 2 files changed, 76 insertions(+), 3 deletions(-) diff --git a/backends/instructions_appendix/all_instructions.golden.adoc b/backends/instructions_appendix/all_instructions.golden.adoc index 347714277..caf82d848 100644 --- a/backends/instructions_appendix/all_instructions.golden.adoc +++ b/backends/instructions_appendix/all_instructions.golden.adoc @@ -3744,6 +3744,9 @@ Included in:: Synopsis:: Breakpoint exception +Assembly:: +c.ebreak + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -4678,6 +4681,9 @@ Included in:: Synopsis:: Compressed May-Be-Operation +Assembly:: +c.mop.n + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -4789,6 +4795,9 @@ Included in:: Synopsis:: Non-operation +Assembly:: +c.nop + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -4859,6 +4868,9 @@ Included in:: Synopsis:: Compressed non-temporal locality hint, all +Assembly:: +c.ntl.all + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -4892,6 +4904,9 @@ Included in:: Synopsis:: Compressed non-temporal locality hint, innermost private +Assembly:: +c.ntl.p1 + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -4925,6 +4940,9 @@ Included in:: Synopsis:: Compressed non-temporal locality hint, all private +Assembly:: +c.ntl.pall + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -4958,6 +4976,9 @@ Included in:: Synopsis:: Compressed non-temporal locality hint, innermost shared +Assembly:: +c.ntl.s1 + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -7278,6 +7299,9 @@ Included in:: Synopsis:: No synopsis available +Assembly:: +dret + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -7307,6 +7331,9 @@ Included in:: Synopsis:: Breakpoint exception +Assembly:: +ebreak + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -7347,6 +7374,9 @@ Included in:: Synopsis:: Environment call +Assembly:: +ecall + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -9992,6 +10022,9 @@ Included in:: Synopsis:: Instruction fence +Assembly:: +fence.i + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -10053,6 +10086,9 @@ Included in:: Synopsis:: Memory ordering fence, total store ordering +Assembly:: +fence.tso + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -15977,6 +16013,9 @@ Included in:: Synopsis:: Machine mode resume from the RNMI or Double Trap handler +Assembly:: +mnret + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -16132,6 +16171,9 @@ Included in:: Synopsis:: Machine-mode Return from Trap +Assembly:: +mret + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -16410,6 +16452,9 @@ Included in:: Synopsis:: Non-temporal locality hint, all +Assembly:: +ntl.all + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -16441,6 +16486,9 @@ Included in:: Synopsis:: Non-temporal locality hint, innermost private +Assembly:: +ntl.p1 + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -16472,6 +16520,9 @@ Included in:: Synopsis:: Non-temporal locality hint, all private +Assembly:: +ntl.pall + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -16503,6 +16554,9 @@ Included in:: Synopsis:: Non-temporal locality hint, innermost shared +Assembly:: +ntl.s1 + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -17767,6 +17821,9 @@ Included in:: Synopsis:: No synopsis available +Assembly:: +sctrclr + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -17975,6 +18032,9 @@ Included in:: Synopsis:: Order implicit page table reads after invalidation +Assembly:: +sfence.inval.ir + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -18243,6 +18303,9 @@ Included in:: Synopsis:: Order writes before sfence +Assembly:: +sfence.w.inval + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -19854,6 +19917,9 @@ Included in:: Synopsis:: Supervisor Mode Return from Trap +Assembly:: +sret + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -46468,6 +46534,9 @@ Included in:: Synopsis:: Wait for interrupt +Assembly:: +wfi + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -46535,6 +46604,9 @@ Included in:: Synopsis:: Wait-on-Reservation-Set-with-No-Timeout +Assembly:: +wrs.nto + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... @@ -46594,6 +46666,9 @@ Included in:: Synopsis:: Wait-on-Reservation-Set-with-Short-Timeout +Assembly:: +wrs.sto + Encoding:: [wavedrom, ,svg,subs='attributes',width="100%"] .... diff --git a/backends/instructions_appendix/templates/instructions.adoc.erb b/backends/instructions_appendix/templates/instructions.adoc.erb index d1e7c7914..5f2ab85de 100755 --- a/backends/instructions_appendix/templates/instructions.adoc.erb +++ b/backends/instructions_appendix/templates/instructions.adoc.erb @@ -10,11 +10,9 @@ Synopsis:: <%= inst.long_name %> -<%- if inst.assembly.to_s.strip != "" -%> Assembly:: -<%= inst.fix_entities("#{inst.name.downcase} #{inst.assembly}") %> +<%= inst.fix_entities("#{inst.name.downcase}#{inst.assembly.to_s.strip == '' ? '' : ' ' + inst.assembly}") %> -<%- end -%> Encoding:: <%- if inst.multi_encoding? -%> [NOTE]