aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@linux.intel.com>2018-06-01 18:02:54 -0700
committerH. Peter Anvin <hpa@linux.intel.com>2018-06-01 18:06:25 -0700
commit98578071b9d71ecaa2344dd9c185237c1765041e (patch)
tree74dfdf8b0f587364f34ae804dc7ce0cd7d81ba7e /test
parent8413e8167a21a922bbf99660165bb091e71bf1c0 (diff)
downloadnasm-98578071b9d71ecaa2344dd9c185237c1765041e.tar.gz
nasm-98578071b9d71ecaa2344dd9c185237c1765041e.tar.xz
nasm-98578071b9d71ecaa2344dd9c185237c1765041e.zip
Cleanup of label renaming infrastructure, add subsection support
In order to support Mach-O better, add support for subsections, as used by Mach-O "subsections_via_symbols". We also want to add infrastructure to support this by downcalling to the backend to indicate if a new subsection is needed. Currently this supports a maximum of 2^14 subsections per section for Mach-O; this can be addressed by adding a level of indirection (or cleaning up the handling of sections so we have an actual data structure.) Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'test')
-rw-r--r--test/subsection.asm7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/subsection.asm b/test/subsection.asm
index f0a1fa03..ce8ed4aa 100644
--- a/test/subsection.asm
+++ b/test/subsection.asm
@@ -5,12 +5,13 @@
;
%pragma output subsections_via_symbols
+%pragma asm gprefix _
+%pragma asm lprefix L_
bits 32
- global foo, bar, quux
-
-%define baz Lbaz
+ global foo, bar
+ static quux
foo:
jmp foo