Skip to content

Commit 7220eeb

Browse files
simplified tests
1 parent 85a4fc3 commit 7220eeb

File tree

2 files changed

+25
-7
lines changed

2 files changed

+25
-7
lines changed

examples/asm/mei/Makefile

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
TARGET = mei
22

3-
$(TARGET).objdump: $(TARGET)
4-
riscv64-unknown-elf-objdump -D $(TARGET) > $(TARGET).objdump
3+
$(TARGET).objdump: $(TARGET).elf
4+
riscv64-unknown-elf-objdump -D $(TARGET).elf > $(TARGET).objdump
55

6-
%: %.S Makefile
6+
%.elf: %.S Makefile
77
riscv64-unknown-elf-gcc -g -o $@ -march=rv64gc -mabi=lp64 -mcmodel=medany \
8-
-nostartfiles -T../../link/link.ld $<
8+
-nostartfiles -Tlink.ld $<
99

1010
sim:
11-
spike -d +signature=$(TARGET).signature.output +signature-granularity=8 $(TARGET)
11+
spike -d +signature=$(TARGET).signature.output +signature-granularity=8 $(TARGET).elf
1212
diff --ignore-case $(TARGET).signature.output $(TARGET).reference_output || exit
1313
echo "Signature matches! Success!"
1414

1515
wally:
16-
wsim rv64gc --elf $(TARGET) --lockstepverbose
16+
wsim rv64gc --elf $(TARGET).elf --lockstepverbose
1717

1818
clean:
19-
rm -f $(TARGET) *.objdump* *.signature.output *.elf* *.memfile
19+
rm -f $(TARGET).elf *.objdump* *.signature.output *.elf* *.memfile

examples/asm/mei/link.ld

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
OUTPUT_ARCH( "riscv" )
2+
ENTRY(rvtest_entry_point)
3+
4+
SECTIONS
5+
{
6+
. = 0x80000000;
7+
.text : { *(.text.init) *(.text) }
8+
. = ALIGN(0x1000);
9+
.tohost : { *(.tohost) }
10+
. = ALIGN(0x4000);
11+
.data : { *(.data) }
12+
.data.string : { *(.data.string)}
13+
. = ALIGN(0x1000);
14+
.bss : { *(.bss) }
15+
. = ALIGN(0x1000);
16+
.text : { *(.text.main) }
17+
_end = .;
18+
}

0 commit comments

Comments
 (0)