annotate portasm/gen-masm.sh @ 551:eef302b7a58d

- amendment fix for buffer overflow (see commit 0455834d29a1), to also handle non-standard struct packing, + better asserts - changelog wording tweaks for clarity - comment tweaks for clarity - (mostly pointless) microoptimization in aggr alignment calculation, avoiding a modulo, as alignment always a power of 2 - cleanups
author Tassilo Philipp
date Mon, 20 Jun 2022 14:57:49 +0200
parents ab2d78e48ca2
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
3e629dc19168 initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
1 #!/bin/sh
341
ab2d78e48ca2 - gen-masm
Tassilo Philipp
parents: 0
diff changeset
2 `which gcc || which clang` -E -P -DGEN_MASM ${1:?Usage: $0 <name> [<outsuffix>]}.S \
ab2d78e48ca2 - gen-masm
Tassilo Philipp
parents: 0
diff changeset
3 | sed "/^$/d;1i\\
ab2d78e48ca2 - gen-masm
Tassilo Philipp
parents: 0
diff changeset
4 ; auto-generated by `basename $0`
ab2d78e48ca2 - gen-masm
Tassilo Philipp
parents: 0
diff changeset
5 ;s/$/ /" \
ab2d78e48ca2 - gen-masm
Tassilo Philipp
parents: 0
diff changeset
6 > $1$2.asm
0
3e629dc19168 initial from svn dyncall-1745
Daniel Adler
parents:
diff changeset
7