aboutsummaryrefslogtreecommitdiffstats
path: root/c_compiler/test/ref
diff options
context:
space:
mode:
Diffstat (limited to 'c_compiler/test/ref')
-rwxr-xr-xc_compiler/test/ref/01bin0 -> 2929088 bytes
-rw-r--r--c_compiler/test/ref/01.s38
-rw-r--r--c_compiler/test/ref/01.stdout.xml9
-rw-r--r--c_compiler/test/ref/02.stdout.xml7
-rw-r--r--c_compiler/test/ref/03.stdout.xml8
-rw-r--r--c_compiler/test/ref/04.stdout.xml12
-rw-r--r--c_compiler/test/ref/05.stdout.xml11
-rw-r--r--c_compiler/test/ref/06.stdout.xml14
-rw-r--r--c_compiler/test/ref/07.stdout.xml11
-rw-r--r--c_compiler/test/ref/08.stdout.xml16
-rw-r--r--c_compiler/test/ref/09.stdout.xml21
-rw-r--r--c_compiler/test/ref/10.stdout.xml20
-rw-r--r--c_compiler/test/ref/11.stdout.xml11
-rw-r--r--c_compiler/test/ref/12.stdout.xml10
-rw-r--r--c_compiler/test/ref/13.stdout.xml13
-rw-r--r--c_compiler/test/ref/14.stdout.xml13
-rw-r--r--c_compiler/test/ref/15.stdout.xml32
17 files changed, 38 insertions, 208 deletions
diff --git a/c_compiler/test/ref/01 b/c_compiler/test/ref/01
new file mode 100755
index 0000000..9655601
--- /dev/null
+++ b/c_compiler/test/ref/01
Binary files differ
diff --git a/c_compiler/test/ref/01.s b/c_compiler/test/ref/01.s
new file mode 100644
index 0000000..db5d0b4
--- /dev/null
+++ b/c_compiler/test/ref/01.s
@@ -0,0 +1,38 @@
+ .file 1 "01.c"
+ .section .mdebug.abi32
+ .previous
+ .nan legacy
+ .module fp=xx
+ .module nooddspreg
+ .abicalls
+ .option pic0
+ .text
+ .align 2
+ .globl main
+ .set nomips16
+ .set nomicromips
+ .ent main
+ .type main, @function
+main:
+ .frame $fp,24,$31 # vars= 8, regs= 1/0, args= 0, gp= 8
+ .mask 0x40000000,-4
+ .fmask 0x00000000,0
+ .set noreorder
+ .set nomacro
+ addiu $sp,$sp,-24
+ sw $fp,20($sp)
+ move $fp,$sp
+ li $2,13 # 0xd
+ sw $2,8($fp)
+ lw $2,8($fp)
+ move $sp,$fp
+ lw $fp,20($sp)
+ addiu $sp,$sp,24
+ jr $31
+ nop
+
+ .set macro
+ .set reorder
+ .end main
+ .size main, .-main
+ .ident "GCC: (Codescape GNU Tools 2016.05-03 for MIPS MTI Linux) 4.9.2"
diff --git a/c_compiler/test/ref/01.stdout.xml b/c_compiler/test/ref/01.stdout.xml
deleted file mode 100644
index e0545e4..0000000
--- a/c_compiler/test/ref/01.stdout.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Variable id="a" />
- <Variable id="b" />
- <Variable id="c" />
- <Variable id="d" />
- <Variable id="e" />
- <Variable id="f" />
-</Program>
diff --git a/c_compiler/test/ref/02.stdout.xml b/c_compiler/test/ref/02.stdout.xml
deleted file mode 100644
index 6caf2fc..0000000
--- a/c_compiler/test/ref/02.stdout.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="f">
- <Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/03.stdout.xml b/c_compiler/test/ref/03.stdout.xml
deleted file mode 100644
index 2c29a50..0000000
--- a/c_compiler/test/ref/03.stdout.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="foo">
- <Parameter id="bar" />
- <Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/04.stdout.xml b/c_compiler/test/ref/04.stdout.xml
deleted file mode 100644
index caae53b..0000000
--- a/c_compiler/test/ref/04.stdout.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="foo">
- <Parameter id="bar1" />
- <Parameter id="bar2" />
- <Scope>
- <Variable id="x" />
- <Variable id="y" />
- <Variable id="z" />
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/05.stdout.xml b/c_compiler/test/ref/05.stdout.xml
deleted file mode 100644
index f4b306f..0000000
--- a/c_compiler/test/ref/05.stdout.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="foo">
- <Parameter id="x" />
- <Parameter id="y" />
- <Scope>
- <Scope>
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/06.stdout.xml b/c_compiler/test/ref/06.stdout.xml
deleted file mode 100644
index 3526139..0000000
--- a/c_compiler/test/ref/06.stdout.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="f">
- <Parameter id="a" />
- <Parameter id="b" />
- <Parameter id="c" />
- <Scope>
- <Variable id="d" />
- <Scope>
- <Variable id="e" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/07.stdout.xml b/c_compiler/test/ref/07.stdout.xml
deleted file mode 100644
index 17c7c1b..0000000
--- a/c_compiler/test/ref/07.stdout.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="foo">
- <Parameter id="a" />
- <Scope>
- <Scope>
- <Variable id="z" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/08.stdout.xml b/c_compiler/test/ref/08.stdout.xml
deleted file mode 100644
index 0838fe5..0000000
--- a/c_compiler/test/ref/08.stdout.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="func">
- <Parameter id="a" />
- <Parameter id="b" />
- <Scope>
- <Variable id="c" />
- <Scope>
- <Variable id="d" />
- </Scope>
- <Scope>
- <Variable id="e" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/09.stdout.xml b/c_compiler/test/ref/09.stdout.xml
deleted file mode 100644
index 646cd98..0000000
--- a/c_compiler/test/ref/09.stdout.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="x">
- <Scope>
- </Scope>
- </Function>
- <Variable id="g" />
- <Function id="zz">
- <Parameter id="a" />
- <Parameter id="b" />
- <Parameter id="c" />
- <Scope>
- <Scope>
- <Variable id="a" />
- </Scope>
- <Scope>
- <Variable id="fsdfsdfs" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/10.stdout.xml b/c_compiler/test/ref/10.stdout.xml
deleted file mode 100644
index 21cadeb..0000000
--- a/c_compiler/test/ref/10.stdout.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="f">
- <Scope>
- </Scope>
- </Function>
- <Variable id="g" />
- <Function id="x">
- <Parameter id="y" />
- <Scope>
- <Variable id="z" />
- <Scope>
- <Variable id="r" />
- </Scope>
- <Scope>
- <Variable id="f" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/11.stdout.xml b/c_compiler/test/ref/11.stdout.xml
deleted file mode 100644
index ad96d6c..0000000
--- a/c_compiler/test/ref/11.stdout.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="f">
- <Scope>
- <Variable id="x" />
- <Scope>
- <Variable id="y" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/12.stdout.xml b/c_compiler/test/ref/12.stdout.xml
deleted file mode 100644
index 9f49265..0000000
--- a/c_compiler/test/ref/12.stdout.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="f">
- <Parameter id="b" />
- <Parameter id="c" />
- <Scope>
- <Variable id="a" />
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/13.stdout.xml b/c_compiler/test/ref/13.stdout.xml
deleted file mode 100644
index f0385cb..0000000
--- a/c_compiler/test/ref/13.stdout.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="func">
- <Parameter id="x" />
- <Parameter id="y" />
- <Scope>
- <Variable id="i" />
- <Scope>
- <Variable id="z" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/14.stdout.xml b/c_compiler/test/ref/14.stdout.xml
deleted file mode 100644
index 63aec85..0000000
--- a/c_compiler/test/ref/14.stdout.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="function_1">
- <Parameter id="a" />
- <Parameter id="b" />
- <Scope>
- <Variable id="x" />
- <Scope>
- <Variable id="c" />
- </Scope>
- </Scope>
- </Function>
-</Program>
diff --git a/c_compiler/test/ref/15.stdout.xml b/c_compiler/test/ref/15.stdout.xml
deleted file mode 100644
index 029ccb8..0000000
--- a/c_compiler/test/ref/15.stdout.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0"?>
-<Program>
- <Function id="add">
- <Parameter id="a" />
- <Parameter id="b" />
- <Scope>
- <Variable id="c" />
- </Scope>
- </Function>
- <Function id="sub">
- <Parameter id="a" />
- <Parameter id="b" />
- <Scope>
- <Variable id="c" />
- </Scope>
- </Function>
- <Function id="mult_by_5">
- <Parameter id="a" />
- <Scope>
- <Variable id="b" />
- </Scope>
- </Function>
- <Function id="add_5">
- <Parameter id="a" />
- <Scope>
- <Variable id="i" />
- <Scope>
- <Variable id="b" />
- </Scope>
- </Scope>
- </Function>
-</Program>