Run more tests.

parent e743dee0
Pipeline #84638233 passed with stages
in 27 minutes and 38 seconds
......@@ -24,12 +24,16 @@ build:
artifacts:
paths:
- artifacts
tags:
- docker
tests:
stage: test
script:
- eatmydata apt-get install -y --no-upgrade python3 qemu-system-x86
- "qemu-system-i386 -hda artifacts/tests/boot_asmg.x86.qcow2 -serial file:/dev/stdout -display none -m 256M -enable-kvm | ./test/decode_tests.py"
tags:
- privileged
mm0:
stage: test
......@@ -37,10 +41,31 @@ mm0:
- eatmydata apt-get install -y --no-upgrade python3 qemu-system-x86
- "qemu-system-i386 -hda artifacts/mm0/boot_asmg.x86.qcow2 -serial file:/dev/stdout -display none -m 256M -enable-kvm | ./test/decode_tests.py just_malloc"
allow_failure: true
tags:
- privileged
tinycc:
ipxe:
stage: test
script:
- eatmydata apt-get install -y --no-upgrade python3 qemu-system-x86
- cd http && python3 -m http.server 8080 &
- "qemu-system-i386 -hda artifacts/tinycc/boot_asmg.x86.qcow2 -serial file:/dev/stdout -display none -m 256M -enable-kvm | ./test/decode_tests.py just_malloc"
- "qemu-system-i386 -hda artifacts/ipxe/boot_asmg.x86.qcow2 -serial file:/dev/stdout -display none -m 256M -enable-kvm | ./test/decode_tests.py just_malloc"
tags:
- privileged
single_cream:
stage: test
script:
- eatmydata apt-get install -y --no-upgrade python3 qemu-system-x86
- "qemu-system-i386 -hda artifacts/single_cream/boot_asmg.x86.qcow2 -serial file:/dev/stdout -display none -m 256M -enable-kvm | ./test/decode_tests.py just_malloc"
allow_failure: true
tags:
- privileged
mm0_c:
stage: test
script:
- eatmydata apt-get install -y --no-upgrade python3 qemu-system-x86
- "qemu-system-i386 -hda artifacts/mm0_c/boot_asmg.x86.qcow2 -serial file:/dev/stdout -display none -m 256M -enable-kvm | ./test/decode_tests.py just_malloc"
tags:
- privileged
......@@ -20,7 +20,7 @@ const TEST_MAP TEST_ALL
const TEST_INT64 TEST_ALL
const TEST_C TEST_ALL
const RUN_MM0 0
const RUN_MM0 1
const RUN_ASM 0
const RUN_FASM 0
const RUN_C 0
......
......@@ -24,9 +24,9 @@
#define LEVEL 0
#endif
#define RUN_IPXE
//#define RUN_SINGLE_CREAM
//#define RUN_MM0_C
#define RUN_IPXE 1
#define RUN_SINGLE_CREAM 0
#define RUN_MM0_C 0
int recursively_compile() {
#if LEVEL == 10
......@@ -45,13 +45,13 @@ int recursively_compile() {
const char *files[1];
printf("Compiling tinycc recursively... (level %d)\n", LEVEL);
#if LEVEL == 1 && defined(RUN_IPXE)
#if LEVEL == 1 && RUN_IPXE
#define ADD_TCC_SYMBOLS
files[0] = ASMC_PREFIX "/run_tcc_ipxe.c";
#elif LEVEL == 1 && defined(RUN_SINGLE_CREAM)
#elif LEVEL == 1 && RUN_SINGLE_CREAM
#define ADD_TCC_SYMBOLS
files[0] = ASMC_PREFIX "/run_tcc_sc.c";
#elif LEVEL == 1 && defined(RUN_MM0_C)
#elif LEVEL == 1 && RUN_MM0_C
#define ADD_TCC_SYMBOLS
files[0] = ASMC_PREFIX "/run_tcc_mm0_c.c";
#else
......
......@@ -3,13 +3,20 @@
mkdir artifacts
mkdir artifacts/tests
mkdir artifacts/mm0
mkdir artifacts/tinycc
mkdir artifacts/ipxe
mkdir artifacts/single_cream
mkdir artifacts/mm0_c
mkdir artifacts/full
set -e
rm -fr build
sed -i -e 's|const TEST_ALL .|const TEST_ALL 1|' asmg/main.g
sed -i -e 's|const RUN_MM0 .|const RUN_MM0 0|' asmg/main.g
sed -i -e 's|const RUN_TINYCC .|const RUN_TINYCC 0|' asmg/main.g
sed -i -e 's|#define RUN_IPXE .|#define RUN_IPXE 1|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_SINGLE_CREAM .|#define RUN_SINGLE_CREAM 0|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_MM0_C .|#define RUN_MM0_C 0|' diskfs/run_tcc.c
make
cp build/boot_asmg.x86.qcow2 build/boot_asmg_dbg.x86.qcow2 artifacts/tests
......@@ -17,6 +24,9 @@ rm -fr build
sed -i -e 's|const TEST_ALL .|const TEST_ALL 0|' asmg/main.g
sed -i -e 's|const RUN_MM0 .|const RUN_MM0 1|' asmg/main.g
sed -i -e 's|const RUN_TINYCC .|const RUN_TINYCC 0|' asmg/main.g
sed -i -e 's|#define RUN_IPXE .|#define RUN_IPXE 1|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_SINGLE_CREAM .|#define RUN_SINGLE_CREAM 0|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_MM0_C .|#define RUN_MM0_C 0|' diskfs/run_tcc.c
make
cp build/boot_asmg.x86.qcow2 build/boot_asmg_dbg.x86.qcow2 artifacts/mm0
......@@ -24,12 +34,38 @@ rm -fr build
sed -i -e 's|const TEST_ALL .|const TEST_ALL 0|' asmg/main.g
sed -i -e 's|const RUN_MM0 .|const RUN_MM0 0|' asmg/main.g
sed -i -e 's|const RUN_TINYCC .|const RUN_TINYCC 1|' asmg/main.g
sed -i -e 's|#define RUN_IPXE .|#define RUN_IPXE 1|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_SINGLE_CREAM .|#define RUN_SINGLE_CREAM 0|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_MM0_C .|#define RUN_MM0_C 0|' diskfs/run_tcc.c
make
cp build/boot_asmg.x86.qcow2 build/boot_asmg_dbg.x86.qcow2 artifacts/ipxe
rm -fr build
sed -i -e 's|const TEST_ALL .|const TEST_ALL 0|' asmg/main.g
sed -i -e 's|const RUN_MM0 .|const RUN_MM0 0|' asmg/main.g
sed -i -e 's|const RUN_TINYCC .|const RUN_TINYCC 1|' asmg/main.g
sed -i -e 's|#define RUN_IPXE .|#define RUN_IPXE 0|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_SINGLE_CREAM .|#define RUN_SINGLE_CREAM 1|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_MM0_C .|#define RUN_MM0_C 0|' diskfs/run_tcc.c
make
cp build/boot_asmg.x86.qcow2 build/boot_asmg_dbg.x86.qcow2 artifacts/single_cream
rm -fr build
sed -i -e 's|const TEST_ALL .|const TEST_ALL 0|' asmg/main.g
sed -i -e 's|const RUN_MM0 .|const RUN_MM0 0|' asmg/main.g
sed -i -e 's|const RUN_TINYCC .|const RUN_TINYCC 1|' asmg/main.g
sed -i -e 's|#define RUN_IPXE .|#define RUN_IPXE 0|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_SINGLE_CREAM .|#define RUN_SINGLE_CREAM 0|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_MM0_C .|#define RUN_MM0_C 1|' diskfs/run_tcc.c
make
cp build/boot_asmg.x86.qcow2 build/boot_asmg_dbg.x86.qcow2 artifacts/tinycc
cp build/boot_asmg.x86.qcow2 build/boot_asmg_dbg.x86.qcow2 artifacts/mm0_c
rm -fr build
sed -i -e 's|const TEST_ALL .|const TEST_ALL 1|' asmg/main.g
sed -i -e 's|const RUN_MM0 .|const RUN_MM0 1|' asmg/main.g
sed -i -e 's|const RUN_TINYCC .|const RUN_TINYCC 1|' asmg/main.g
sed -i -e 's|#define RUN_IPXE .|#define RUN_IPXE 1|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_SINGLE_CREAM .|#define RUN_SINGLE_CREAM 0|' diskfs/run_tcc.c
sed -i -e 's|#define RUN_MM0_C .|#define RUN_MM0_C 0|' diskfs/run_tcc.c
make
cp build/boot_asmg.x86.qcow2 build/boot_asmg_dbg.x86.qcow2 artifacts/full
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment