17 lines
626 B
Bash
Executable File
17 lines
626 B
Bash
Executable File
#!/bin/sh
|
|
# M2 test gate: rebuild the linked COFF through the normal GSPA/GSPLNK path,
|
|
# then verify dis34 decodes the TI-ABI instructions at the linked addresses.
|
|
set -eu
|
|
ROOT=$(cd "$(dirname "$0")/../../.." && pwd)
|
|
|
|
# Always rebuild: a stale build/m2/m2.coff would let an asm-encoding
|
|
# regression pass without ever touching the compiler or assembler. Keep
|
|
# dis-roundtrip.sh pointed at the file this run produces, including when
|
|
# M2_WORK/M2_COFF are overridden.
|
|
WORK=${M2_WORK:-$ROOT/build/m2}
|
|
M2_COFF=${M2_COFF:-$WORK/m2.coff}
|
|
export M2_COFF
|
|
|
|
"$ROOT/scripts/m2/run.sh" "$@"
|
|
exec "$ROOT/scripts/m2/dis-roundtrip.sh" "$@"
|