Added simple vec test
This commit is contained in:
@@ -35,7 +35,7 @@ void vx_resetStack(void);
|
||||
|
||||
|
||||
#define __if(b) vx_split(b); \
|
||||
if (b) \
|
||||
if (b)
|
||||
|
||||
#define __else else
|
||||
|
||||
|
||||
@@ -170,24 +170,25 @@ int main (int argc, char **argv) {
|
||||
|
||||
|
||||
// CTX initialization
|
||||
context_t ctx;
|
||||
memset(&ctx, 0, sizeof(context_t));
|
||||
ctx.num_groups[0] = 2;
|
||||
ctx.num_groups[1] = 1;
|
||||
ctx.num_groups[2] = 1;
|
||||
printf("ctx size: %d\n", sizeof(context_t));
|
||||
context_t * ctx = (context_t *) malloc(sizeof(context_t));
|
||||
memset(ctx, 0, sizeof(context_t));
|
||||
ctx->num_groups[0] = 4;
|
||||
ctx->num_groups[1] = 1;
|
||||
ctx->num_groups[2] = 1;
|
||||
|
||||
ctx.global_offset[0] = 0;
|
||||
ctx.global_offset[1] = 0;
|
||||
ctx.global_offset[2] = 0;
|
||||
ctx->global_offset[0] = 0;
|
||||
ctx->global_offset[1] = 0;
|
||||
ctx->global_offset[2] = 0;
|
||||
|
||||
ctx.local_size[0] = 2;
|
||||
ctx.local_size[1] = 1;
|
||||
ctx.local_size[2] = 1;
|
||||
ctx->local_size[0] = 1;
|
||||
ctx->local_size[1] = 1;
|
||||
ctx->local_size[2] = 1;
|
||||
|
||||
ctx.printf_buffer = NULL;
|
||||
ctx.printf_buffer_position = 0;
|
||||
ctx.printf_buffer_capacity = 0;
|
||||
ctx.work_dim = 1;
|
||||
ctx->printf_buffer = NULL;
|
||||
ctx->printf_buffer_position = 0;
|
||||
ctx->printf_buffer_capacity = 0;
|
||||
ctx->work_dim = 1;
|
||||
|
||||
// Arguments initialization
|
||||
void **args = (void **)malloc (sizeof(void *) * (p_num_args + p_num_locals));
|
||||
@@ -199,8 +200,9 @@ int main (int argc, char **argv) {
|
||||
printf("B address: %x\n", B);
|
||||
printf("C address: %x\n", C);
|
||||
printf("args address: %x\n", args);
|
||||
printf("CTX address: %x\n", ctx);
|
||||
|
||||
pocl_spawn(&ctx, p_pfn, (void *) args);
|
||||
pocl_spawn(ctx, p_pfn, (void *) args);
|
||||
|
||||
// Testing
|
||||
for (i = 0; i < SIZE; ++i)
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
File diff suppressed because it is too large
Load Diff
34
runtime/mains/vector_test/Makefile
Normal file
34
runtime/mains/vector_test/Makefile
Normal file
@@ -0,0 +1,34 @@
|
||||
|
||||
COMP = /home/fares/dev/riscv-gnu-toolchain-vector/drops/bin/riscv32-unknown-elf-gcc
|
||||
|
||||
CC_FLAGS = -ffreestanding -O0 -Wl,--gc-sections -nostartfiles -nostdlib -nostartfiles -nodefaultlibs -Wl,-Bstatic,-T,linker.ld -march=rv32imv -mabi=ilp32
|
||||
|
||||
DMP = /home/fares/dev/riscv-gnu-toolchain-vector/drops/bin/riscv32-unknown-elf-objdump
|
||||
CPY = /home/fares/dev/riscv-gnu-toolchain-vector/drops/bin/riscv32-unknown-elf-objcopy
|
||||
|
||||
# VX_STR = ../../startup/vx_start.s
|
||||
|
||||
|
||||
|
||||
NEWLIB = ../../newlib/newlib.c
|
||||
VX_STR = ../../startup/vx_start.s
|
||||
VX_INT = ../../intrinsics/vx_intrinsics.s
|
||||
VX_IO = ../../io/vx_io.s ../../io/vx_io.c
|
||||
VX_API = ../../vx_api/vx_api.c
|
||||
VX_TEST = ../../tests/tests.c
|
||||
VX_FIO = ../../fileio/fileio.s
|
||||
VX_VEC = vx_vec.s
|
||||
LIBS = /home/fares/dev/riscv-gnu-toolchain-vector/drops/riscv32-unknown-elf/lib/libc.a /home/fares/dev/riscv-gnu-toolchain-vector/drops/riscv32-unknown-elf/lib/libstdc++.a -static-libgcc -lgcc
|
||||
|
||||
VX_MAIN = vx_vector_main
|
||||
|
||||
all: HEX DUMP ELF
|
||||
|
||||
DUMP: ELF
|
||||
$(DMP) -D $(VX_MAIN).elf > $(VX_MAIN).dump
|
||||
|
||||
HEX: ELF
|
||||
$(CPY) -O ihex $(VX_MAIN).elf $(VX_MAIN).hex
|
||||
|
||||
ELF:
|
||||
$(COMP) $(CC_FLAGS) $(VX_STR) $(VX_VEC) $(VX_FIO) $(NEWLIB) $(VX_INT) $(VX_IO) $(VX_API) $(VX_TEST) $(VX_MAIN).c $(LIBS) -Iinclude -o $(VX_MAIN).elf
|
||||
242
runtime/mains/vector_test/linker.ld
Normal file
242
runtime/mains/vector_test/linker.ld
Normal file
@@ -0,0 +1,242 @@
|
||||
/* ---- Original Script: /opt/riscv32i/riscv32-unknown-elf/lib/ldscripts/elf32lriscv.x ---- */
|
||||
/* Default linker script, for normal executables */
|
||||
/* Copyright (C) 2014-2017 Free Software Foundation, Inc.
|
||||
Copying and distribution of this script, with or without modification,
|
||||
are permitted in any medium without royalty provided the copyright
|
||||
notice and this notice are preserved. */
|
||||
OUTPUT_FORMAT("elf32-littleriscv", "elf32-littleriscv",
|
||||
"elf32-littleriscv")
|
||||
OUTPUT_ARCH(riscv)
|
||||
ENTRY(_start)
|
||||
SECTIONS
|
||||
{
|
||||
PROVIDE(__stack_top = 0x6ffff000);
|
||||
. = 0x80000000;
|
||||
.init :
|
||||
{
|
||||
KEEP (*(SORT_NONE(.init)))
|
||||
}
|
||||
.text :
|
||||
{
|
||||
*(.text.unlikely .text.*_unlikely .text.unlikely.*)
|
||||
*(.text.exit .text.exit.*)
|
||||
*(.text.startup .text.startup.*)
|
||||
*(.text.hot .text.hot.*)
|
||||
*(.text .stub .text.* .gnu.linkonce.t.*)
|
||||
/* .gnu.warning sections are handled specially by elf32.em. */
|
||||
*(.gnu.warning)
|
||||
}
|
||||
.interp : { *(.interp) }
|
||||
.note.gnu.build-id : { *(.note.gnu.build-id) }
|
||||
.hash : { *(.hash) }
|
||||
.gnu.hash : { *(.gnu.hash) }
|
||||
.dynsym : { *(.dynsym) }
|
||||
.dynstr : { *(.dynstr) }
|
||||
.gnu.version : { *(.gnu.version) }
|
||||
.gnu.version_d : { *(.gnu.version_d) }
|
||||
.gnu.version_r : { *(.gnu.version_r) }
|
||||
.rela.dyn :
|
||||
{
|
||||
*(.rela.init)
|
||||
*(.rela.text .rela.text.* .rela.gnu.linkonce.t.*)
|
||||
*(.rela.fini)
|
||||
*(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*)
|
||||
*(.rela.data .rela.data.* .rela.gnu.linkonce.d.*)
|
||||
*(.rela.tdata .rela.tdata.* .rela.gnu.linkonce.td.*)
|
||||
*(.rela.tbss .rela.tbss.* .rela.gnu.linkonce.tb.*)
|
||||
*(.rela.ctors)
|
||||
*(.rela.dtors)
|
||||
*(.rela.got)
|
||||
*(.rela.sdata .rela.sdata.* .rela.gnu.linkonce.s.*)
|
||||
*(.rela.sbss .rela.sbss.* .rela.gnu.linkonce.sb.*)
|
||||
*(.rela.sdata2 .rela.sdata2.* .rela.gnu.linkonce.s2.*)
|
||||
*(.rela.sbss2 .rela.sbss2.* .rela.gnu.linkonce.sb2.*)
|
||||
*(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*)
|
||||
PROVIDE_HIDDEN (__rela_iplt_start = .);
|
||||
*(.rela.iplt)
|
||||
PROVIDE_HIDDEN (__rela_iplt_end = .);
|
||||
}
|
||||
.rela.plt :
|
||||
{
|
||||
*(.rela.plt)
|
||||
}
|
||||
.plt : { *(.plt) }
|
||||
.iplt : { *(.iplt) }
|
||||
.fini :
|
||||
{
|
||||
KEEP (*(SORT_NONE(.fini)))
|
||||
}
|
||||
PROVIDE (__etext = .);
|
||||
PROVIDE (_etext = .);
|
||||
PROVIDE (etext = .);
|
||||
.rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) }
|
||||
.rodata1 : { *(.rodata1) }
|
||||
.sdata2 :
|
||||
{
|
||||
*(.sdata2 .sdata2.* .gnu.linkonce.s2.*)
|
||||
}
|
||||
.sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
|
||||
.eh_frame_hdr : { *(.eh_frame_hdr) *(.eh_frame_entry .eh_frame_entry.*) }
|
||||
.eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) *(.eh_frame.*) }
|
||||
.gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
|
||||
.gnu_extab : ONLY_IF_RO { *(.gnu_extab*) }
|
||||
/* These sections are generated by the Sun/Oracle C++ compiler. */
|
||||
.exception_ranges : ONLY_IF_RO { *(.exception_ranges*) }
|
||||
/* Adjust the address for the data segment. We want to adjust up to
|
||||
the same address within the page on the next page up. */
|
||||
. = DATA_SEGMENT_ALIGN (CONSTANT (MAXPAGESIZE), CONSTANT (COMMONPAGESIZE));
|
||||
/* Exception handling */
|
||||
.eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) *(.eh_frame.*) }
|
||||
.gnu_extab : ONLY_IF_RW { *(.gnu_extab) }
|
||||
.gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
|
||||
.exception_ranges : ONLY_IF_RW { *(.exception_ranges*) }
|
||||
/* Thread Local Storage sections */
|
||||
.tdata :
|
||||
{
|
||||
PROVIDE_HIDDEN (__tdata_start = .);
|
||||
*(.tdata .tdata.* .gnu.linkonce.td.*)
|
||||
}
|
||||
.tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
|
||||
.preinit_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__preinit_array_start = .);
|
||||
KEEP (*(.preinit_array))
|
||||
PROVIDE_HIDDEN (__preinit_array_end = .);
|
||||
}
|
||||
.init_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__init_array_start = .);
|
||||
KEEP (*(SORT_BY_INIT_PRIORITY(.init_array.*) SORT_BY_INIT_PRIORITY(.ctors.*)))
|
||||
KEEP (*(.init_array EXCLUDE_FILE (*crtbegin.o *crtbegin?.o *crtend.o *crtend?.o ) .ctors))
|
||||
PROVIDE_HIDDEN (__init_array_end = .);
|
||||
}
|
||||
.fini_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__fini_array_start = .);
|
||||
KEEP (*(SORT_BY_INIT_PRIORITY(.fini_array.*) SORT_BY_INIT_PRIORITY(.dtors.*)))
|
||||
KEEP (*(.fini_array EXCLUDE_FILE (*crtbegin.o *crtbegin?.o *crtend.o *crtend?.o ) .dtors))
|
||||
PROVIDE_HIDDEN (__fini_array_end = .);
|
||||
}
|
||||
.ctors :
|
||||
{
|
||||
/* gcc uses crtbegin.o to find the start of
|
||||
the constructors, so we make sure it is
|
||||
first. Because this is a wildcard, it
|
||||
doesn't matter if the user does not
|
||||
actually link against crtbegin.o; the
|
||||
linker won't look for a file to match a
|
||||
wildcard. The wildcard also means that it
|
||||
doesn't matter which directory crtbegin.o
|
||||
is in. */
|
||||
KEEP (*crtbegin.o(.ctors))
|
||||
KEEP (*crtbegin?.o(.ctors))
|
||||
/* We don't want to include the .ctor section from
|
||||
the crtend.o file until after the sorted ctors.
|
||||
The .ctor section from the crtend file contains the
|
||||
end of ctors marker and it must be last */
|
||||
KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .ctors))
|
||||
KEEP (*(SORT(.ctors.*)))
|
||||
KEEP (*(.ctors))
|
||||
}
|
||||
.dtors :
|
||||
{
|
||||
KEEP (*crtbegin.o(.dtors))
|
||||
KEEP (*crtbegin?.o(.dtors))
|
||||
KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .dtors))
|
||||
KEEP (*(SORT(.dtors.*)))
|
||||
KEEP (*(.dtors))
|
||||
}
|
||||
.jcr : { KEEP (*(.jcr)) }
|
||||
.data.rel.ro : { *(.data.rel.ro.local* .gnu.linkonce.d.rel.ro.local.*) *(.data.rel.ro .data.rel.ro.* .gnu.linkonce.d.rel.ro.*) }
|
||||
.dynamic : { *(.dynamic) }
|
||||
. = DATA_SEGMENT_RELRO_END (0, .);
|
||||
.data :
|
||||
{
|
||||
__DATA_BEGIN__ = .;
|
||||
*(.data .data.* .gnu.linkonce.d.*)
|
||||
SORT(CONSTRUCTORS)
|
||||
}
|
||||
.data1 : { *(.data1) }
|
||||
.got : { *(.got.plt) *(.igot.plt) *(.got) *(.igot) }
|
||||
/* We want the small data sections together, so single-instruction offsets
|
||||
can access them all, and initialized data all before uninitialized, so
|
||||
we can shorten the on-disk segment size. */
|
||||
.sdata :
|
||||
{
|
||||
__SDATA_BEGIN__ = .;
|
||||
*(.srodata.cst16) *(.srodata.cst8) *(.srodata.cst4) *(.srodata.cst2) *(.srodata .srodata.*)
|
||||
*(.sdata .sdata.* .gnu.linkonce.s.*)
|
||||
}
|
||||
_edata = .; PROVIDE (edata = .);
|
||||
. = .;
|
||||
__bss_start = .;
|
||||
.sbss :
|
||||
{
|
||||
*(.dynsbss)
|
||||
*(.sbss .sbss.* .gnu.linkonce.sb.*)
|
||||
*(.scommon)
|
||||
}
|
||||
.bss :
|
||||
{
|
||||
*(.dynbss)
|
||||
*(.bss .bss.* .gnu.linkonce.b.*)
|
||||
*(COMMON)
|
||||
/* Align here to ensure that the .bss section occupies space up to
|
||||
_end. Align after .bss to ensure correct alignment even if the
|
||||
.bss section disappears because there are no input sections.
|
||||
FIXME: Why do we need it? When there is no .bss section, we do not
|
||||
pad the .data section. */
|
||||
. = ALIGN(. != 0 ? 32 / 8 : 1);
|
||||
}
|
||||
. = ALIGN(32 / 8);
|
||||
. = SEGMENT_START("ldata-segment", .);
|
||||
. = ALIGN(32 / 8);
|
||||
__BSS_END__ = .;
|
||||
__global_pointer$ = MIN(__SDATA_BEGIN__ + 0x800,
|
||||
MAX(__DATA_BEGIN__ + 0x800, __BSS_END__ - 0x800));
|
||||
_end = .; PROVIDE (end = .);
|
||||
. = DATA_SEGMENT_END (.);
|
||||
/* Stabs debugging sections. */
|
||||
.stab 0 : { *(.stab) }
|
||||
.stabstr 0 : { *(.stabstr) }
|
||||
.stab.excl 0 : { *(.stab.excl) }
|
||||
.stab.exclstr 0 : { *(.stab.exclstr) }
|
||||
.stab.index 0 : { *(.stab.index) }
|
||||
.stab.indexstr 0 : { *(.stab.indexstr) }
|
||||
.comment 0 : { *(.comment) }
|
||||
.gnu.build.attributes : { *(.gnu.build.attributes .gnu.build.attributes.*) }
|
||||
/* DWARF debug sections.
|
||||
Symbols in the DWARF debugging sections are relative to the beginning
|
||||
of the section so we begin them at 0. */
|
||||
/* DWARF 1 */
|
||||
.debug 0 : { *(.debug) }
|
||||
.line 0 : { *(.line) }
|
||||
/* GNU DWARF 1 extensions */
|
||||
.debug_srcinfo 0 : { *(.debug_srcinfo) }
|
||||
.debug_sfnames 0 : { *(.debug_sfnames) }
|
||||
/* DWARF 1.1 and DWARF 2 */
|
||||
.debug_aranges 0 : { *(.debug_aranges) }
|
||||
.debug_pubnames 0 : { *(.debug_pubnames) }
|
||||
/* DWARF 2 */
|
||||
.debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) }
|
||||
.debug_abbrev 0 : { *(.debug_abbrev) }
|
||||
.debug_line 0 : { *(.debug_line .debug_line.* .debug_line_end) }
|
||||
.debug_frame 0 : { *(.debug_frame) }
|
||||
.debug_str 0 : { *(.debug_str) }
|
||||
.debug_loc 0 : { *(.debug_loc) }
|
||||
.debug_macinfo 0 : { *(.debug_macinfo) }
|
||||
/* SGI/MIPS DWARF 2 extensions */
|
||||
.debug_weaknames 0 : { *(.debug_weaknames) }
|
||||
.debug_funcnames 0 : { *(.debug_funcnames) }
|
||||
.debug_typenames 0 : { *(.debug_typenames) }
|
||||
.debug_varnames 0 : { *(.debug_varnames) }
|
||||
/* DWARF 3 */
|
||||
.debug_pubtypes 0 : { *(.debug_pubtypes) }
|
||||
.debug_ranges 0 : { *(.debug_ranges) }
|
||||
/* DWARF Extension. */
|
||||
.debug_macro 0 : { *(.debug_macro) }
|
||||
.debug_addr 0 : { *(.debug_addr) }
|
||||
.gnu.attributes 0 : { KEEP (*(.gnu.attributes)) }
|
||||
/DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) }
|
||||
|
||||
}
|
||||
15
runtime/mains/vector_test/vx_vec.h
Normal file
15
runtime/mains/vector_test/vx_vec.h
Normal file
@@ -0,0 +1,15 @@
|
||||
|
||||
|
||||
#pragma once
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void vx_vec_test();
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
9
runtime/mains/vector_test/vx_vec.s
Normal file
9
runtime/mains/vector_test/vx_vec.s
Normal file
@@ -0,0 +1,9 @@
|
||||
|
||||
|
||||
|
||||
.type vx_vec_test, @function
|
||||
.global vx_vec_test
|
||||
vx_vec_test:
|
||||
vsetvli t0, x0, e32
|
||||
vadd.vv v0, v0, v0
|
||||
ret
|
||||
8
runtime/mains/vector_test/vx_vector_main.c
Normal file
8
runtime/mains/vector_test/vx_vector_main.c
Normal file
@@ -0,0 +1,8 @@
|
||||
|
||||
#include "vx_vec.h"
|
||||
|
||||
int main()
|
||||
{
|
||||
vx_tmc(1);
|
||||
vx_vec_test();
|
||||
}
|
||||
776
runtime/mains/vector_test/vx_vector_main.dump
Normal file
776
runtime/mains/vector_test/vx_vector_main.dump
Normal file
@@ -0,0 +1,776 @@
|
||||
|
||||
vx_vector_main.elf: file format elf32-littleriscv
|
||||
|
||||
|
||||
Disassembly of section .init:
|
||||
|
||||
80000000 <_start>:
|
||||
80000000: 00000597 auipc a1,0x0
|
||||
80000004: 07458593 addi a1,a1,116 # 80000074 <vx_set_sp>
|
||||
80000008: 00400513 li a0,4
|
||||
8000000c: 00b5106b 0xb5106b
|
||||
80000010: 064000ef jal ra,80000074 <vx_set_sp>
|
||||
80000014: 00100513 li a0,1
|
||||
80000018: 0005006b 0x5006b
|
||||
8000001c: 00002517 auipc a0,0x2
|
||||
80000020: da450513 addi a0,a0,-604 # 80001dc0 <_edata>
|
||||
80000024: 00002617 auipc a2,0x2
|
||||
80000028: da060613 addi a2,a2,-608 # 80001dc4 <__BSS_END__>
|
||||
8000002c: 40a60633 sub a2,a2,a0
|
||||
80000030: 00000593 li a1,0
|
||||
80000034: 6c0000ef jal ra,800006f4 <memset>
|
||||
80000038: 00000517 auipc a0,0x0
|
||||
8000003c: 5c050513 addi a0,a0,1472 # 800005f8 <__libc_fini_array>
|
||||
80000040: 574000ef jal ra,800005b4 <atexit>
|
||||
80000044: 614000ef jal ra,80000658 <__libc_init_array>
|
||||
80000048: 00400513 li a0,4
|
||||
8000004c: 0005006b 0x5006b
|
||||
80000050: 530000ef jal ra,80000580 <main>
|
||||
80000054: 5740006f j 800005c8 <exit>
|
||||
|
||||
Disassembly of section .text:
|
||||
|
||||
80000058 <register_fini>:
|
||||
80000058: 000007b7 lui a5,0x0
|
||||
8000005c: 00078793 mv a5,a5
|
||||
80000060: 00078863 beqz a5,80000070 <register_fini+0x18>
|
||||
80000064: 80000537 lui a0,0x80000
|
||||
80000068: 5f850513 addi a0,a0,1528 # 800005f8 <__global_pointer$+0xffffe470>
|
||||
8000006c: 5480006f j 800005b4 <atexit>
|
||||
80000070: 00008067 ret
|
||||
|
||||
80000074 <vx_set_sp>:
|
||||
80000074: 00400513 li a0,4
|
||||
80000078: 0005006b 0x5006b
|
||||
8000007c: 00002197 auipc gp,0x2
|
||||
80000080: 10c18193 addi gp,gp,268 # 80002188 <__global_pointer$>
|
||||
80000084: 021026f3 csrr a3,0x21
|
||||
80000088: 01a69693 slli a3,a3,0x1a
|
||||
8000008c: 02002673 csrr a2,0x20
|
||||
80000090: 00a61593 slli a1,a2,0xa
|
||||
80000094: 00261613 slli a2,a2,0x2
|
||||
80000098: 6ffff137 lui sp,0x6ffff
|
||||
8000009c: 40b10133 sub sp,sp,a1
|
||||
800000a0: 40d10133 sub sp,sp,a3
|
||||
800000a4: 00c10133 add sp,sp,a2
|
||||
800000a8: 021026f3 csrr a3,0x21
|
||||
800000ac: 00068663 beqz a3,800000b8 <RETURN>
|
||||
800000b0: 00000513 li a0,0
|
||||
800000b4: 0005006b 0x5006b
|
||||
|
||||
800000b8 <RETURN>:
|
||||
800000b8: 00008067 ret
|
||||
|
||||
800000bc <vx_vec_test>:
|
||||
800000bc: 008072d7 vsetvli t0,zero,e32,m1,d1
|
||||
800000c0: 02000057 vadd.vv v0,v0,v0
|
||||
800000c4: 00008067 ret
|
||||
|
||||
800000c8 <upload>:
|
||||
800000c8: fd010113 addi sp,sp,-48 # 6fffefd0 <_start-0x10001030>
|
||||
800000cc: 02812623 sw s0,44(sp)
|
||||
800000d0: 03010413 addi s0,sp,48
|
||||
800000d4: fca42e23 sw a0,-36(s0)
|
||||
800000d8: fcb42c23 sw a1,-40(s0)
|
||||
800000dc: fcc42a23 sw a2,-44(s0)
|
||||
800000e0: fdc42783 lw a5,-36(s0)
|
||||
800000e4: 0007a783 lw a5,0(a5) # 0 <_start-0x80000000>
|
||||
800000e8: fef42623 sw a5,-20(s0)
|
||||
800000ec: fd442783 lw a5,-44(s0)
|
||||
800000f0: fef42223 sw a5,-28(s0)
|
||||
800000f4: fe442783 lw a5,-28(s0)
|
||||
800000f8: 0007c703 lbu a4,0(a5)
|
||||
800000fc: fec42783 lw a5,-20(s0)
|
||||
80000100: 00e78023 sb a4,0(a5)
|
||||
80000104: fec42783 lw a5,-20(s0)
|
||||
80000108: 00178793 addi a5,a5,1
|
||||
8000010c: fe442703 lw a4,-28(s0)
|
||||
80000110: 00174703 lbu a4,1(a4)
|
||||
80000114: 00e78023 sb a4,0(a5)
|
||||
80000118: fec42783 lw a5,-20(s0)
|
||||
8000011c: 00278793 addi a5,a5,2
|
||||
80000120: fe442703 lw a4,-28(s0)
|
||||
80000124: 00274703 lbu a4,2(a4)
|
||||
80000128: 00e78023 sb a4,0(a5)
|
||||
8000012c: fec42783 lw a5,-20(s0)
|
||||
80000130: 00378793 addi a5,a5,3
|
||||
80000134: fe442703 lw a4,-28(s0)
|
||||
80000138: 00374703 lbu a4,3(a4)
|
||||
8000013c: 00e78023 sb a4,0(a5)
|
||||
80000140: fec42783 lw a5,-20(s0)
|
||||
80000144: 00478793 addi a5,a5,4
|
||||
80000148: fef42623 sw a5,-20(s0)
|
||||
8000014c: fe042423 sw zero,-24(s0)
|
||||
80000150: 0340006f j 80000184 <upload+0xbc>
|
||||
80000154: fe842783 lw a5,-24(s0)
|
||||
80000158: fd842703 lw a4,-40(s0)
|
||||
8000015c: 00f707b3 add a5,a4,a5
|
||||
80000160: 0007c703 lbu a4,0(a5)
|
||||
80000164: fec42783 lw a5,-20(s0)
|
||||
80000168: 00e78023 sb a4,0(a5)
|
||||
8000016c: fec42783 lw a5,-20(s0)
|
||||
80000170: 00178793 addi a5,a5,1
|
||||
80000174: fef42623 sw a5,-20(s0)
|
||||
80000178: fe842783 lw a5,-24(s0)
|
||||
8000017c: 00178793 addi a5,a5,1
|
||||
80000180: fef42423 sw a5,-24(s0)
|
||||
80000184: fe842703 lw a4,-24(s0)
|
||||
80000188: fd442783 lw a5,-44(s0)
|
||||
8000018c: fcf744e3 blt a4,a5,80000154 <upload+0x8c>
|
||||
80000190: fdc42783 lw a5,-36(s0)
|
||||
80000194: fec42703 lw a4,-20(s0)
|
||||
80000198: 00e7a023 sw a4,0(a5)
|
||||
8000019c: 00000013 nop
|
||||
800001a0: 02c12403 lw s0,44(sp)
|
||||
800001a4: 03010113 addi sp,sp,48
|
||||
800001a8: 00008067 ret
|
||||
|
||||
800001ac <download>:
|
||||
800001ac: fd010113 addi sp,sp,-48
|
||||
800001b0: 02812623 sw s0,44(sp)
|
||||
800001b4: 03010413 addi s0,sp,48
|
||||
800001b8: fca42e23 sw a0,-36(s0)
|
||||
800001bc: fcb42c23 sw a1,-40(s0)
|
||||
800001c0: fdc42783 lw a5,-36(s0)
|
||||
800001c4: 0007a783 lw a5,0(a5)
|
||||
800001c8: fef42623 sw a5,-20(s0)
|
||||
800001cc: fe442783 lw a5,-28(s0)
|
||||
800001d0: fef42023 sw a5,-32(s0)
|
||||
800001d4: fec42783 lw a5,-20(s0)
|
||||
800001d8: 0007c703 lbu a4,0(a5)
|
||||
800001dc: fe042783 lw a5,-32(s0)
|
||||
800001e0: 00e78023 sb a4,0(a5)
|
||||
800001e4: fe042783 lw a5,-32(s0)
|
||||
800001e8: 00178793 addi a5,a5,1
|
||||
800001ec: fec42703 lw a4,-20(s0)
|
||||
800001f0: 00174703 lbu a4,1(a4)
|
||||
800001f4: 00e78023 sb a4,0(a5)
|
||||
800001f8: fe042783 lw a5,-32(s0)
|
||||
800001fc: 00278793 addi a5,a5,2
|
||||
80000200: fec42703 lw a4,-20(s0)
|
||||
80000204: 00274703 lbu a4,2(a4)
|
||||
80000208: 00e78023 sb a4,0(a5)
|
||||
8000020c: fe042783 lw a5,-32(s0)
|
||||
80000210: 00378793 addi a5,a5,3
|
||||
80000214: fec42703 lw a4,-20(s0)
|
||||
80000218: 00374703 lbu a4,3(a4)
|
||||
8000021c: 00e78023 sb a4,0(a5)
|
||||
80000220: fec42783 lw a5,-20(s0)
|
||||
80000224: 00478793 addi a5,a5,4
|
||||
80000228: fef42623 sw a5,-20(s0)
|
||||
8000022c: fe042423 sw zero,-24(s0)
|
||||
80000230: 0340006f j 80000264 <download+0xb8>
|
||||
80000234: fe842783 lw a5,-24(s0)
|
||||
80000238: fd842703 lw a4,-40(s0)
|
||||
8000023c: 00f707b3 add a5,a4,a5
|
||||
80000240: fec42703 lw a4,-20(s0)
|
||||
80000244: 00074703 lbu a4,0(a4)
|
||||
80000248: 00e78023 sb a4,0(a5)
|
||||
8000024c: fec42783 lw a5,-20(s0)
|
||||
80000250: 00178793 addi a5,a5,1
|
||||
80000254: fef42623 sw a5,-20(s0)
|
||||
80000258: fe842783 lw a5,-24(s0)
|
||||
8000025c: 00178793 addi a5,a5,1
|
||||
80000260: fef42423 sw a5,-24(s0)
|
||||
80000264: fe842703 lw a4,-24(s0)
|
||||
80000268: fe442783 lw a5,-28(s0)
|
||||
8000026c: fcf744e3 blt a4,a5,80000234 <download+0x88>
|
||||
80000270: fdc42783 lw a5,-36(s0)
|
||||
80000274: fec42703 lw a4,-20(s0)
|
||||
80000278: 00e7a023 sw a4,0(a5)
|
||||
8000027c: 00000013 nop
|
||||
80000280: 02c12403 lw s0,44(sp)
|
||||
80000284: 03010113 addi sp,sp,48
|
||||
80000288: 00008067 ret
|
||||
|
||||
8000028c <_close>:
|
||||
8000028c: ff010113 addi sp,sp,-16
|
||||
80000290: 00812623 sw s0,12(sp)
|
||||
80000294: 01010413 addi s0,sp,16
|
||||
80000298: 00000013 nop
|
||||
8000029c: 00c12403 lw s0,12(sp)
|
||||
800002a0: 01010113 addi sp,sp,16
|
||||
800002a4: 00008067 ret
|
||||
|
||||
800002a8 <_fstat>:
|
||||
800002a8: fe010113 addi sp,sp,-32
|
||||
800002ac: 00812e23 sw s0,28(sp)
|
||||
800002b0: 02010413 addi s0,sp,32
|
||||
800002b4: fea42623 sw a0,-20(s0)
|
||||
800002b8: feb42423 sw a1,-24(s0)
|
||||
800002bc: fe842783 lw a5,-24(s0)
|
||||
800002c0: 00002737 lui a4,0x2
|
||||
800002c4: 00e7a223 sw a4,4(a5)
|
||||
800002c8: 00000793 li a5,0
|
||||
800002cc: 00078513 mv a0,a5
|
||||
800002d0: 01c12403 lw s0,28(sp)
|
||||
800002d4: 02010113 addi sp,sp,32
|
||||
800002d8: 00008067 ret
|
||||
|
||||
800002dc <_isatty>:
|
||||
800002dc: fe010113 addi sp,sp,-32
|
||||
800002e0: 00812e23 sw s0,28(sp)
|
||||
800002e4: 02010413 addi s0,sp,32
|
||||
800002e8: fea42623 sw a0,-20(s0)
|
||||
800002ec: 00100793 li a5,1
|
||||
800002f0: 00078513 mv a0,a5
|
||||
800002f4: 01c12403 lw s0,28(sp)
|
||||
800002f8: 02010113 addi sp,sp,32
|
||||
800002fc: 00008067 ret
|
||||
|
||||
80000300 <_lseek>:
|
||||
80000300: ff010113 addi sp,sp,-16
|
||||
80000304: 00812623 sw s0,12(sp)
|
||||
80000308: 01010413 addi s0,sp,16
|
||||
8000030c: 00000013 nop
|
||||
80000310: 00c12403 lw s0,12(sp)
|
||||
80000314: 01010113 addi sp,sp,16
|
||||
80000318: 00008067 ret
|
||||
|
||||
8000031c <_read>:
|
||||
8000031c: ff010113 addi sp,sp,-16
|
||||
80000320: 00812623 sw s0,12(sp)
|
||||
80000324: 01010413 addi s0,sp,16
|
||||
80000328: 00000013 nop
|
||||
8000032c: 00c12403 lw s0,12(sp)
|
||||
80000330: 01010113 addi sp,sp,16
|
||||
80000334: 00008067 ret
|
||||
|
||||
80000338 <_write>:
|
||||
80000338: fd010113 addi sp,sp,-48
|
||||
8000033c: 02812623 sw s0,44(sp)
|
||||
80000340: 03010413 addi s0,sp,48
|
||||
80000344: fca42e23 sw a0,-36(s0)
|
||||
80000348: fcb42c23 sw a1,-40(s0)
|
||||
8000034c: fcc42a23 sw a2,-44(s0)
|
||||
80000350: 000107b7 lui a5,0x10
|
||||
80000354: fef42423 sw a5,-24(s0)
|
||||
80000358: fe042623 sw zero,-20(s0)
|
||||
8000035c: 02c0006f j 80000388 <_write+0x50>
|
||||
80000360: fec42783 lw a5,-20(s0)
|
||||
80000364: fd842703 lw a4,-40(s0)
|
||||
80000368: 00f707b3 add a5,a4,a5
|
||||
8000036c: 0007c783 lbu a5,0(a5) # 10000 <_start-0x7fff0000>
|
||||
80000370: 00078713 mv a4,a5
|
||||
80000374: fe842783 lw a5,-24(s0)
|
||||
80000378: 00e7a023 sw a4,0(a5)
|
||||
8000037c: fec42783 lw a5,-20(s0)
|
||||
80000380: 00178793 addi a5,a5,1
|
||||
80000384: fef42623 sw a5,-20(s0)
|
||||
80000388: fec42703 lw a4,-20(s0)
|
||||
8000038c: fd442783 lw a5,-44(s0)
|
||||
80000390: fcf748e3 blt a4,a5,80000360 <_write+0x28>
|
||||
80000394: fd442783 lw a5,-44(s0)
|
||||
80000398: 00078513 mv a0,a5
|
||||
8000039c: 02c12403 lw s0,44(sp)
|
||||
800003a0: 03010113 addi sp,sp,48
|
||||
800003a4: 00008067 ret
|
||||
|
||||
800003a8 <_sbrk>:
|
||||
800003a8: fd010113 addi sp,sp,-48
|
||||
800003ac: 02812623 sw s0,44(sp)
|
||||
800003b0: 03010413 addi s0,sp,48
|
||||
800003b4: fca42e23 sw a0,-36(s0)
|
||||
800003b8: fdc42783 lw a5,-36(s0)
|
||||
800003bc: 0007d863 bgez a5,800003cc <_sbrk+0x24>
|
||||
800003c0: fdc42783 lw a5,-36(s0)
|
||||
800003c4: 40f007b3 neg a5,a5
|
||||
800003c8: fcf42e23 sw a5,-36(s0)
|
||||
800003cc: fdc42703 lw a4,-36(s0)
|
||||
800003d0: 000037b7 lui a5,0x3
|
||||
800003d4: 80078793 addi a5,a5,-2048 # 2800 <_start-0x7fffd800>
|
||||
800003d8: 00e7d863 bge a5,a4,800003e8 <_sbrk+0x40>
|
||||
800003dc: 000037b7 lui a5,0x3
|
||||
800003e0: 80078793 addi a5,a5,-2048 # 2800 <_start-0x7fffd800>
|
||||
800003e4: fcf42e23 sw a5,-36(s0)
|
||||
800003e8: c301a783 lw a5,-976(gp) # 80001db8 <heap_start>
|
||||
800003ec: fef42623 sw a5,-20(s0)
|
||||
800003f0: c301a703 lw a4,-976(gp) # 80001db8 <heap_start>
|
||||
800003f4: fdc42783 lw a5,-36(s0)
|
||||
800003f8: 00f70733 add a4,a4,a5
|
||||
800003fc: c2e1a823 sw a4,-976(gp) # 80001db8 <heap_start>
|
||||
80000400: fec42783 lw a5,-20(s0)
|
||||
80000404: 00078513 mv a0,a5
|
||||
80000408: 02c12403 lw s0,44(sp)
|
||||
8000040c: 03010113 addi sp,sp,48
|
||||
80000410: 00008067 ret
|
||||
|
||||
80000414 <_exit>:
|
||||
80000414: fe010113 addi sp,sp,-32
|
||||
80000418: 00112e23 sw ra,28(sp)
|
||||
8000041c: 00812c23 sw s0,24(sp)
|
||||
80000420: 02010413 addi s0,sp,32
|
||||
80000424: fea42623 sw a0,-20(s0)
|
||||
80000428: 00000513 li a0,0
|
||||
8000042c: 0e4000ef jal ra,80000510 <vx_tmc>
|
||||
80000430: 00000013 nop
|
||||
80000434: 01c12083 lw ra,28(sp)
|
||||
80000438: 01812403 lw s0,24(sp)
|
||||
8000043c: 02010113 addi sp,sp,32
|
||||
80000440: 00008067 ret
|
||||
|
||||
80000444 <_open>:
|
||||
80000444: ff010113 addi sp,sp,-16
|
||||
80000448: 00812623 sw s0,12(sp)
|
||||
8000044c: 01010413 addi s0,sp,16
|
||||
80000450: 00000013 nop
|
||||
80000454: 00c12403 lw s0,12(sp)
|
||||
80000458: 01010113 addi sp,sp,16
|
||||
8000045c: 00008067 ret
|
||||
|
||||
80000460 <_kill>:
|
||||
80000460: ff010113 addi sp,sp,-16
|
||||
80000464: 00812623 sw s0,12(sp)
|
||||
80000468: 01010413 addi s0,sp,16
|
||||
8000046c: 00000013 nop
|
||||
80000470: 00c12403 lw s0,12(sp)
|
||||
80000474: 01010113 addi sp,sp,16
|
||||
80000478: 00008067 ret
|
||||
|
||||
8000047c <_getpid>:
|
||||
8000047c: ff010113 addi sp,sp,-16
|
||||
80000480: 00112623 sw ra,12(sp)
|
||||
80000484: 00812423 sw s0,8(sp)
|
||||
80000488: 01010413 addi s0,sp,16
|
||||
8000048c: 0ac000ef jal ra,80000538 <vx_threadID>
|
||||
80000490: 00050793 mv a5,a0
|
||||
80000494: 00078513 mv a0,a5
|
||||
80000498: 00c12083 lw ra,12(sp)
|
||||
8000049c: 00812403 lw s0,8(sp)
|
||||
800004a0: 01010113 addi sp,sp,16
|
||||
800004a4: 00008067 ret
|
||||
|
||||
800004a8 <_unlink>:
|
||||
800004a8: ff010113 addi sp,sp,-16
|
||||
800004ac: 00812623 sw s0,12(sp)
|
||||
800004b0: 01010413 addi s0,sp,16
|
||||
800004b4: 00000013 nop
|
||||
800004b8: 00c12403 lw s0,12(sp)
|
||||
800004bc: 01010113 addi sp,sp,16
|
||||
800004c0: 00008067 ret
|
||||
|
||||
800004c4 <_gettimeofday>:
|
||||
800004c4: ff010113 addi sp,sp,-16
|
||||
800004c8: 00812623 sw s0,12(sp)
|
||||
800004cc: 01010413 addi s0,sp,16
|
||||
800004d0: c381a783 lw a5,-968(gp) # 80001dc0 <_edata>
|
||||
800004d4: 00178693 addi a3,a5,1
|
||||
800004d8: c2d1ac23 sw a3,-968(gp) # 80001dc0 <_edata>
|
||||
800004dc: 00078513 mv a0,a5
|
||||
800004e0: 00c12403 lw s0,12(sp)
|
||||
800004e4: 01010113 addi sp,sp,16
|
||||
800004e8: 00008067 ret
|
||||
|
||||
800004ec <_link>:
|
||||
800004ec: ff010113 addi sp,sp,-16
|
||||
800004f0: 00812623 sw s0,12(sp)
|
||||
800004f4: 01010413 addi s0,sp,16
|
||||
800004f8: 00000013 nop
|
||||
800004fc: 00c12403 lw s0,12(sp)
|
||||
80000500: 01010113 addi sp,sp,16
|
||||
80000504: 00008067 ret
|
||||
|
||||
80000508 <vx_wspawn>:
|
||||
80000508: 00b5106b 0xb5106b
|
||||
8000050c: 00008067 ret
|
||||
|
||||
80000510 <vx_tmc>:
|
||||
80000510: 0005006b 0x5006b
|
||||
80000514: 00008067 ret
|
||||
|
||||
80000518 <vx_barrier>:
|
||||
80000518: 00b5406b 0xb5406b
|
||||
8000051c: 00008067 ret
|
||||
|
||||
80000520 <vx_split>:
|
||||
80000520: 0005206b 0x5206b
|
||||
80000524: 00008067 ret
|
||||
|
||||
80000528 <vx_join>:
|
||||
80000528: 0000306b 0x306b
|
||||
8000052c: 00008067 ret
|
||||
|
||||
80000530 <vx_warpID>:
|
||||
80000530: 02102573 csrr a0,0x21
|
||||
80000534: 00008067 ret
|
||||
|
||||
80000538 <vx_threadID>:
|
||||
80000538: 02002573 csrr a0,0x20
|
||||
8000053c: 00008067 ret
|
||||
|
||||
80000540 <vx_resetStack>:
|
||||
80000540: 00400513 li a0,4
|
||||
80000544: 0005006b 0x5006b
|
||||
80000548: 021026f3 csrr a3,0x21
|
||||
8000054c: 00f69693 slli a3,a3,0xf
|
||||
80000550: 02002673 csrr a2,0x20
|
||||
80000554: 00a61593 slli a1,a2,0xa
|
||||
80000558: 00261613 slli a2,a2,0x2
|
||||
8000055c: 6ffff137 lui sp,0x6ffff
|
||||
80000560: 40b10133 sub sp,sp,a1
|
||||
80000564: 40d10133 sub sp,sp,a3
|
||||
80000568: 00c10133 add sp,sp,a2
|
||||
8000056c: 021026f3 csrr a3,0x21
|
||||
80000570: 00068663 beqz a3,8000057c <RETURN>
|
||||
80000574: 00000513 li a0,0
|
||||
80000578: 0005006b 0x5006b
|
||||
|
||||
8000057c <RETURN>:
|
||||
8000057c: 00008067 ret
|
||||
|
||||
80000580 <main>:
|
||||
80000580: ff010113 addi sp,sp,-16 # 6fffeff0 <_start-0x10001010>
|
||||
80000584: 00112623 sw ra,12(sp)
|
||||
80000588: 00812423 sw s0,8(sp)
|
||||
8000058c: 01010413 addi s0,sp,16
|
||||
80000590: 00100513 li a0,1
|
||||
80000594: f7dff0ef jal ra,80000510 <vx_tmc>
|
||||
80000598: b25ff0ef jal ra,800000bc <vx_vec_test>
|
||||
8000059c: 00000013 nop
|
||||
800005a0: 00078513 mv a0,a5
|
||||
800005a4: 00c12083 lw ra,12(sp)
|
||||
800005a8: 00812403 lw s0,8(sp)
|
||||
800005ac: 01010113 addi sp,sp,16
|
||||
800005b0: 00008067 ret
|
||||
|
||||
800005b4 <atexit>:
|
||||
800005b4: 00050593 mv a1,a0
|
||||
800005b8: 00000693 li a3,0
|
||||
800005bc: 00000613 li a2,0
|
||||
800005c0: 00000513 li a0,0
|
||||
800005c4: 20c0006f j 800007d0 <__register_exitproc>
|
||||
|
||||
800005c8 <exit>:
|
||||
800005c8: ff010113 addi sp,sp,-16
|
||||
800005cc: 00000593 li a1,0
|
||||
800005d0: 00812423 sw s0,8(sp)
|
||||
800005d4: 00112623 sw ra,12(sp)
|
||||
800005d8: 00050413 mv s0,a0
|
||||
800005dc: 28c000ef jal ra,80000868 <__call_exitprocs>
|
||||
800005e0: c281a503 lw a0,-984(gp) # 80001db0 <_global_impure_ptr>
|
||||
800005e4: 03c52783 lw a5,60(a0)
|
||||
800005e8: 00078463 beqz a5,800005f0 <exit+0x28>
|
||||
800005ec: 000780e7 jalr a5
|
||||
800005f0: 00040513 mv a0,s0
|
||||
800005f4: e21ff0ef jal ra,80000414 <_exit>
|
||||
|
||||
800005f8 <__libc_fini_array>:
|
||||
800005f8: ff010113 addi sp,sp,-16
|
||||
800005fc: 00812423 sw s0,8(sp)
|
||||
80000600: 00912223 sw s1,4(sp)
|
||||
80000604: 80002437 lui s0,0x80002
|
||||
80000608: 800024b7 lui s1,0x80002
|
||||
8000060c: 98448793 addi a5,s1,-1660 # 80001984 <__global_pointer$+0xfffff7fc>
|
||||
80000610: 98440413 addi s0,s0,-1660 # 80001984 <__global_pointer$+0xfffff7fc>
|
||||
80000614: 40f40433 sub s0,s0,a5
|
||||
80000618: 00112623 sw ra,12(sp)
|
||||
8000061c: 40245413 srai s0,s0,0x2
|
||||
80000620: 02040263 beqz s0,80000644 <__libc_fini_array+0x4c>
|
||||
80000624: 00241493 slli s1,s0,0x2
|
||||
80000628: ffc48493 addi s1,s1,-4
|
||||
8000062c: 00f484b3 add s1,s1,a5
|
||||
80000630: 0004a783 lw a5,0(s1)
|
||||
80000634: fff40413 addi s0,s0,-1
|
||||
80000638: ffc48493 addi s1,s1,-4
|
||||
8000063c: 000780e7 jalr a5
|
||||
80000640: fe0418e3 bnez s0,80000630 <__libc_fini_array+0x38>
|
||||
80000644: 00c12083 lw ra,12(sp)
|
||||
80000648: 00812403 lw s0,8(sp)
|
||||
8000064c: 00412483 lw s1,4(sp)
|
||||
80000650: 01010113 addi sp,sp,16
|
||||
80000654: 00008067 ret
|
||||
|
||||
80000658 <__libc_init_array>:
|
||||
80000658: ff010113 addi sp,sp,-16
|
||||
8000065c: 00812423 sw s0,8(sp)
|
||||
80000660: 01212023 sw s2,0(sp)
|
||||
80000664: 80002437 lui s0,0x80002
|
||||
80000668: 80002937 lui s2,0x80002
|
||||
8000066c: 98040793 addi a5,s0,-1664 # 80001980 <__global_pointer$+0xfffff7f8>
|
||||
80000670: 98090913 addi s2,s2,-1664 # 80001980 <__global_pointer$+0xfffff7f8>
|
||||
80000674: 40f90933 sub s2,s2,a5
|
||||
80000678: 00112623 sw ra,12(sp)
|
||||
8000067c: 00912223 sw s1,4(sp)
|
||||
80000680: 40295913 srai s2,s2,0x2
|
||||
80000684: 02090063 beqz s2,800006a4 <__libc_init_array+0x4c>
|
||||
80000688: 98040413 addi s0,s0,-1664
|
||||
8000068c: 00000493 li s1,0
|
||||
80000690: 00042783 lw a5,0(s0)
|
||||
80000694: 00148493 addi s1,s1,1
|
||||
80000698: 00440413 addi s0,s0,4
|
||||
8000069c: 000780e7 jalr a5
|
||||
800006a0: fe9918e3 bne s2,s1,80000690 <__libc_init_array+0x38>
|
||||
800006a4: 80002437 lui s0,0x80002
|
||||
800006a8: 80002937 lui s2,0x80002
|
||||
800006ac: 98040793 addi a5,s0,-1664 # 80001980 <__global_pointer$+0xfffff7f8>
|
||||
800006b0: 98490913 addi s2,s2,-1660 # 80001984 <__global_pointer$+0xfffff7fc>
|
||||
800006b4: 40f90933 sub s2,s2,a5
|
||||
800006b8: 40295913 srai s2,s2,0x2
|
||||
800006bc: 02090063 beqz s2,800006dc <__libc_init_array+0x84>
|
||||
800006c0: 98040413 addi s0,s0,-1664
|
||||
800006c4: 00000493 li s1,0
|
||||
800006c8: 00042783 lw a5,0(s0)
|
||||
800006cc: 00148493 addi s1,s1,1
|
||||
800006d0: 00440413 addi s0,s0,4
|
||||
800006d4: 000780e7 jalr a5
|
||||
800006d8: fe9918e3 bne s2,s1,800006c8 <__libc_init_array+0x70>
|
||||
800006dc: 00c12083 lw ra,12(sp)
|
||||
800006e0: 00812403 lw s0,8(sp)
|
||||
800006e4: 00412483 lw s1,4(sp)
|
||||
800006e8: 00012903 lw s2,0(sp)
|
||||
800006ec: 01010113 addi sp,sp,16
|
||||
800006f0: 00008067 ret
|
||||
|
||||
800006f4 <memset>:
|
||||
800006f4: 00f00313 li t1,15
|
||||
800006f8: 00050713 mv a4,a0
|
||||
800006fc: 02c37e63 bgeu t1,a2,80000738 <memset+0x44>
|
||||
80000700: 00f77793 andi a5,a4,15
|
||||
80000704: 0a079063 bnez a5,800007a4 <memset+0xb0>
|
||||
80000708: 08059263 bnez a1,8000078c <memset+0x98>
|
||||
8000070c: ff067693 andi a3,a2,-16
|
||||
80000710: 00f67613 andi a2,a2,15
|
||||
80000714: 00e686b3 add a3,a3,a4
|
||||
80000718: 00b72023 sw a1,0(a4) # 2000 <_start-0x7fffe000>
|
||||
8000071c: 00b72223 sw a1,4(a4)
|
||||
80000720: 00b72423 sw a1,8(a4)
|
||||
80000724: 00b72623 sw a1,12(a4)
|
||||
80000728: 01070713 addi a4,a4,16
|
||||
8000072c: fed766e3 bltu a4,a3,80000718 <memset+0x24>
|
||||
80000730: 00061463 bnez a2,80000738 <memset+0x44>
|
||||
80000734: 00008067 ret
|
||||
80000738: 40c306b3 sub a3,t1,a2
|
||||
8000073c: 00269693 slli a3,a3,0x2
|
||||
80000740: 00000297 auipc t0,0x0
|
||||
80000744: 005686b3 add a3,a3,t0
|
||||
80000748: 00c68067 jr 12(a3)
|
||||
8000074c: 00b70723 sb a1,14(a4)
|
||||
80000750: 00b706a3 sb a1,13(a4)
|
||||
80000754: 00b70623 sb a1,12(a4)
|
||||
80000758: 00b705a3 sb a1,11(a4)
|
||||
8000075c: 00b70523 sb a1,10(a4)
|
||||
80000760: 00b704a3 sb a1,9(a4)
|
||||
80000764: 00b70423 sb a1,8(a4)
|
||||
80000768: 00b703a3 sb a1,7(a4)
|
||||
8000076c: 00b70323 sb a1,6(a4)
|
||||
80000770: 00b702a3 sb a1,5(a4)
|
||||
80000774: 00b70223 sb a1,4(a4)
|
||||
80000778: 00b701a3 sb a1,3(a4)
|
||||
8000077c: 00b70123 sb a1,2(a4)
|
||||
80000780: 00b700a3 sb a1,1(a4)
|
||||
80000784: 00b70023 sb a1,0(a4)
|
||||
80000788: 00008067 ret
|
||||
8000078c: 0ff5f593 andi a1,a1,255
|
||||
80000790: 00859693 slli a3,a1,0x8
|
||||
80000794: 00d5e5b3 or a1,a1,a3
|
||||
80000798: 01059693 slli a3,a1,0x10
|
||||
8000079c: 00d5e5b3 or a1,a1,a3
|
||||
800007a0: f6dff06f j 8000070c <memset+0x18>
|
||||
800007a4: 00279693 slli a3,a5,0x2
|
||||
800007a8: 00000297 auipc t0,0x0
|
||||
800007ac: 005686b3 add a3,a3,t0
|
||||
800007b0: 00008293 mv t0,ra
|
||||
800007b4: fa0680e7 jalr -96(a3)
|
||||
800007b8: 00028093 mv ra,t0
|
||||
800007bc: ff078793 addi a5,a5,-16
|
||||
800007c0: 40f70733 sub a4,a4,a5
|
||||
800007c4: 00f60633 add a2,a2,a5
|
||||
800007c8: f6c378e3 bgeu t1,a2,80000738 <memset+0x44>
|
||||
800007cc: f3dff06f j 80000708 <memset+0x14>
|
||||
|
||||
800007d0 <__register_exitproc>:
|
||||
800007d0: c281a703 lw a4,-984(gp) # 80001db0 <_global_impure_ptr>
|
||||
800007d4: 14872783 lw a5,328(a4)
|
||||
800007d8: 04078c63 beqz a5,80000830 <__register_exitproc+0x60>
|
||||
800007dc: 0047a703 lw a4,4(a5)
|
||||
800007e0: 01f00813 li a6,31
|
||||
800007e4: 06e84e63 blt a6,a4,80000860 <__register_exitproc+0x90>
|
||||
800007e8: 00271813 slli a6,a4,0x2
|
||||
800007ec: 02050663 beqz a0,80000818 <__register_exitproc+0x48>
|
||||
800007f0: 01078333 add t1,a5,a6
|
||||
800007f4: 08c32423 sw a2,136(t1)
|
||||
800007f8: 1887a883 lw a7,392(a5)
|
||||
800007fc: 00100613 li a2,1
|
||||
80000800: 00e61633 sll a2,a2,a4
|
||||
80000804: 00c8e8b3 or a7,a7,a2
|
||||
80000808: 1917a423 sw a7,392(a5)
|
||||
8000080c: 10d32423 sw a3,264(t1)
|
||||
80000810: 00200693 li a3,2
|
||||
80000814: 02d50463 beq a0,a3,8000083c <__register_exitproc+0x6c>
|
||||
80000818: 00170713 addi a4,a4,1
|
||||
8000081c: 00e7a223 sw a4,4(a5)
|
||||
80000820: 010787b3 add a5,a5,a6
|
||||
80000824: 00b7a423 sw a1,8(a5)
|
||||
80000828: 00000513 li a0,0
|
||||
8000082c: 00008067 ret
|
||||
80000830: 14c70793 addi a5,a4,332
|
||||
80000834: 14f72423 sw a5,328(a4)
|
||||
80000838: fa5ff06f j 800007dc <__register_exitproc+0xc>
|
||||
8000083c: 18c7a683 lw a3,396(a5)
|
||||
80000840: 00170713 addi a4,a4,1
|
||||
80000844: 00e7a223 sw a4,4(a5)
|
||||
80000848: 00c6e633 or a2,a3,a2
|
||||
8000084c: 18c7a623 sw a2,396(a5)
|
||||
80000850: 010787b3 add a5,a5,a6
|
||||
80000854: 00b7a423 sw a1,8(a5)
|
||||
80000858: 00000513 li a0,0
|
||||
8000085c: 00008067 ret
|
||||
80000860: fff00513 li a0,-1
|
||||
80000864: 00008067 ret
|
||||
|
||||
80000868 <__call_exitprocs>:
|
||||
80000868: fd010113 addi sp,sp,-48
|
||||
8000086c: 01812423 sw s8,8(sp)
|
||||
80000870: c281ac03 lw s8,-984(gp) # 80001db0 <_global_impure_ptr>
|
||||
80000874: 01312e23 sw s3,28(sp)
|
||||
80000878: 01412c23 sw s4,24(sp)
|
||||
8000087c: 01512a23 sw s5,20(sp)
|
||||
80000880: 01612823 sw s6,16(sp)
|
||||
80000884: 02112623 sw ra,44(sp)
|
||||
80000888: 02812423 sw s0,40(sp)
|
||||
8000088c: 02912223 sw s1,36(sp)
|
||||
80000890: 03212023 sw s2,32(sp)
|
||||
80000894: 01712623 sw s7,12(sp)
|
||||
80000898: 00050a93 mv s5,a0
|
||||
8000089c: 00058b13 mv s6,a1
|
||||
800008a0: 00100a13 li s4,1
|
||||
800008a4: fff00993 li s3,-1
|
||||
800008a8: 148c2903 lw s2,328(s8)
|
||||
800008ac: 02090863 beqz s2,800008dc <__call_exitprocs+0x74>
|
||||
800008b0: 00492483 lw s1,4(s2)
|
||||
800008b4: fff48413 addi s0,s1,-1
|
||||
800008b8: 02044263 bltz s0,800008dc <__call_exitprocs+0x74>
|
||||
800008bc: 00249493 slli s1,s1,0x2
|
||||
800008c0: 009904b3 add s1,s2,s1
|
||||
800008c4: 040b0463 beqz s6,8000090c <__call_exitprocs+0xa4>
|
||||
800008c8: 1044a783 lw a5,260(s1)
|
||||
800008cc: 05678063 beq a5,s6,8000090c <__call_exitprocs+0xa4>
|
||||
800008d0: fff40413 addi s0,s0,-1
|
||||
800008d4: ffc48493 addi s1,s1,-4
|
||||
800008d8: ff3416e3 bne s0,s3,800008c4 <__call_exitprocs+0x5c>
|
||||
800008dc: 02c12083 lw ra,44(sp)
|
||||
800008e0: 02812403 lw s0,40(sp)
|
||||
800008e4: 02412483 lw s1,36(sp)
|
||||
800008e8: 02012903 lw s2,32(sp)
|
||||
800008ec: 01c12983 lw s3,28(sp)
|
||||
800008f0: 01812a03 lw s4,24(sp)
|
||||
800008f4: 01412a83 lw s5,20(sp)
|
||||
800008f8: 01012b03 lw s6,16(sp)
|
||||
800008fc: 00c12b83 lw s7,12(sp)
|
||||
80000900: 00812c03 lw s8,8(sp)
|
||||
80000904: 03010113 addi sp,sp,48
|
||||
80000908: 00008067 ret
|
||||
8000090c: 00492783 lw a5,4(s2)
|
||||
80000910: 0044a683 lw a3,4(s1)
|
||||
80000914: fff78793 addi a5,a5,-1
|
||||
80000918: 04878a63 beq a5,s0,8000096c <__call_exitprocs+0x104>
|
||||
8000091c: 0004a223 sw zero,4(s1)
|
||||
80000920: fa0688e3 beqz a3,800008d0 <__call_exitprocs+0x68>
|
||||
80000924: 18892783 lw a5,392(s2)
|
||||
80000928: 008a1733 sll a4,s4,s0
|
||||
8000092c: 00492b83 lw s7,4(s2)
|
||||
80000930: 00f777b3 and a5,a4,a5
|
||||
80000934: 00079e63 bnez a5,80000950 <__call_exitprocs+0xe8>
|
||||
80000938: 000680e7 jalr a3
|
||||
8000093c: 00492783 lw a5,4(s2)
|
||||
80000940: f77794e3 bne a5,s7,800008a8 <__call_exitprocs+0x40>
|
||||
80000944: 148c2783 lw a5,328(s8)
|
||||
80000948: f92784e3 beq a5,s2,800008d0 <__call_exitprocs+0x68>
|
||||
8000094c: f5dff06f j 800008a8 <__call_exitprocs+0x40>
|
||||
80000950: 18c92783 lw a5,396(s2)
|
||||
80000954: 0844a583 lw a1,132(s1)
|
||||
80000958: 00f77733 and a4,a4,a5
|
||||
8000095c: 00071c63 bnez a4,80000974 <__call_exitprocs+0x10c>
|
||||
80000960: 000a8513 mv a0,s5
|
||||
80000964: 000680e7 jalr a3
|
||||
80000968: fd5ff06f j 8000093c <__call_exitprocs+0xd4>
|
||||
8000096c: 00892223 sw s0,4(s2)
|
||||
80000970: fb1ff06f j 80000920 <__call_exitprocs+0xb8>
|
||||
80000974: 00058513 mv a0,a1
|
||||
80000978: 000680e7 jalr a3
|
||||
8000097c: fc1ff06f j 8000093c <__call_exitprocs+0xd4>
|
||||
|
||||
Disassembly of section .init_array:
|
||||
|
||||
80001980 <__init_array_start>:
|
||||
80001980: 0058 addi a4,sp,4
|
||||
80001982: 8000 0x8000
|
||||
|
||||
Disassembly of section .data:
|
||||
|
||||
80001988 <__DATA_BEGIN__>:
|
||||
80001988: 0000 unimp
|
||||
8000198a: 0000 unimp
|
||||
8000198c: 1c74 addi a3,sp,572
|
||||
8000198e: 8000 0x8000
|
||||
80001990: 1cdc addi a5,sp,628
|
||||
80001992: 8000 0x8000
|
||||
80001994: 1d44 addi s1,sp,692
|
||||
80001996: 8000 0x8000
|
||||
...
|
||||
80001a30: 0001 nop
|
||||
80001a32: 0000 unimp
|
||||
80001a34: 0000 unimp
|
||||
80001a36: 0000 unimp
|
||||
80001a38: 330e fld ft6,224(sp)
|
||||
80001a3a: abcd j 8000202c <__BSS_END__+0x268>
|
||||
80001a3c: 1234 addi a3,sp,296
|
||||
80001a3e: e66d bnez a2,80001b28 <__DATA_BEGIN__+0x1a0>
|
||||
80001a40: deec sw a1,124(a3)
|
||||
80001a42: 0005 c.nop 1
|
||||
80001a44: 0000000b 0xb
|
||||
...
|
||||
|
||||
Disassembly of section .sdata:
|
||||
|
||||
80001db0 <_global_impure_ptr>:
|
||||
80001db0: 1988 addi a0,sp,240
|
||||
80001db2: 8000 0x8000
|
||||
|
||||
80001db4 <trap_to_simulator>:
|
||||
80001db4: 0000 unimp
|
||||
80001db6: 7000 flw fs0,32(s0)
|
||||
|
||||
80001db8 <heap_start>:
|
||||
80001db8: 0000 unimp
|
||||
80001dba: 1000 addi s0,sp,32
|
||||
|
||||
80001dbc <head_end>:
|
||||
80001dbc: 0000 unimp
|
||||
80001dbe: 2000 fld fs0,0(s0)
|
||||
|
||||
Disassembly of section .bss:
|
||||
|
||||
80001dc0 <__bss_start>:
|
||||
80001dc0: 0000 unimp
|
||||
...
|
||||
|
||||
Disassembly of section .comment:
|
||||
|
||||
00000000 <.comment>:
|
||||
0: 3a434347 fmsub.d ft6,ft6,ft4,ft7,rmm
|
||||
4: 2820 fld fs0,80(s0)
|
||||
6: 29554e47 fmsub.s ft8,fa0,fs5,ft5,rmm
|
||||
a: 3820 fld fs0,112(s0)
|
||||
c: 332e fld ft6,232(sp)
|
||||
e: 302e fld ft0,232(sp)
|
||||
...
|
||||
|
||||
Disassembly of section .riscv.attributes:
|
||||
|
||||
00000000 <.riscv.attributes>:
|
||||
0: 2341 jal 580 <_start-0x7ffffa80>
|
||||
2: 0000 unimp
|
||||
4: 7200 flw fs0,32(a2)
|
||||
6: 7369 lui t1,0xffffa
|
||||
8: 01007663 bgeu zero,a6,14 <_start-0x7fffffec>
|
||||
c: 0019 c.nop 6
|
||||
e: 0000 unimp
|
||||
10: 7205 lui tp,0xfffe1
|
||||
12: 3376 fld ft6,376(sp)
|
||||
14: 6932 flw fs2,12(sp)
|
||||
16: 7032 flw ft0,44(sp)
|
||||
18: 5f30 lw a2,120(a4)
|
||||
1a: 326d jal fffff9c4 <__global_pointer$+0x7fffd83c>
|
||||
1c: 3070 fld fa2,224(s0)
|
||||
1e: 765f 7032 0030 0x307032765f
|
||||
BIN
runtime/mains/vector_test/vx_vector_main.elf
Normal file
BIN
runtime/mains/vector_test/vx_vector_main.elf
Normal file
Binary file not shown.
225
runtime/mains/vector_test/vx_vector_main.hex
Normal file
225
runtime/mains/vector_test/vx_vector_main.hex
Normal file
@@ -0,0 +1,225 @@
|
||||
:0200000480007A
|
||||
:100000009705000093854507130540006B10B50068
|
||||
:10001000EF004006130510006B00050017250000D7
|
||||
:10002000130545DA17260000130606DA3306A64044
|
||||
:1000300093050000EF00006C170500001305055C38
|
||||
:10004000EF004057EF004061130540006B000500D2
|
||||
:08005000EF0000536F00405760
|
||||
:10005800B70700009387070063880700370500800B
|
||||
:100068001305855F6F00805467800000130540000A
|
||||
:100078006B000500972100009381C110F326100240
|
||||
:100088009396A601732600029315A6001316260060
|
||||
:1000980037F1FF6F3301B1403301D1403301C10063
|
||||
:1000A800F326100263860600130500006B000500A6
|
||||
:1000B80067800000D7728000570000026780000048
|
||||
:1000C800130101FD2326810213040103232EA4FC3E
|
||||
:1000D800232CB4FC232AC4FC8327C4FD83A7070070
|
||||
:1000E8002326F4FE832744FD2322F4FE832744FEBF
|
||||
:1000F80003C707008327C4FE2380E7008327C4FEC5
|
||||
:1001080093871700032744FE034717002380E7005F
|
||||
:100118008327C4FE93872700032744FE034727004D
|
||||
:100128002380E7008327C4FE93873700032744FE14
|
||||
:10013800034737002380E7008327C4FE93874700DF
|
||||
:100148002326F4FE232404FE6F004003832784FE45
|
||||
:10015800032784FDB307F70003C707008327C4FEFE
|
||||
:100168002380E7008327C4FE938717002326F4FE25
|
||||
:10017800832784FE938717002324F4FE032784FE35
|
||||
:10018800832744FDE344F7FC8327C4FD0327C4FE0B
|
||||
:1001980023A0E700130000000324C1021301010398
|
||||
:1001A80067800000130101FD232681021304010367
|
||||
:1001B800232EA4FC232CB4FC8327C4FD83A70700AB
|
||||
:1001C8002326F4FE832744FE2320F4FE8327C4FE5F
|
||||
:1001D80003C70700832704FE2380E700832704FE64
|
||||
:1001E800938717000327C4FE034717002380E700FF
|
||||
:1001F800832704FE938727000327C4FE03472700AD
|
||||
:100208002380E700832704FE938737000327C4FE73
|
||||
:10021800034737002380E7008327C4FE93874700FE
|
||||
:100228002326F4FE232404FE6F004003832784FE64
|
||||
:10023800032784FDB307F7000327C4FE034707001D
|
||||
:100248002380E7008327C4FE938717002326F4FE44
|
||||
:10025800832784FE938717002324F4FE032784FE54
|
||||
:10026800832744FEE344F7FC8327C4FD0327C4FE29
|
||||
:1002780023A0E700130000000324C10213010103B7
|
||||
:1002880067800000130101FF232681001304010188
|
||||
:10029800130000000324C10013010101678000005E
|
||||
:1002A800130101FE232E8100130401022326A4FE5C
|
||||
:1002B8002324B4FE832784FE3727000023A2E70007
|
||||
:1002C80093070000138507000324C10113010102ED
|
||||
:1002D80067800000130101FE232E81001304010230
|
||||
:1002E8002326A4FE93071000138507000324C101E9
|
||||
:1002F8001301010267800000130101FF232681001A
|
||||
:1003080013040101130000000324C10013010101BB
|
||||
:1003180067800000130101FF2326810013040101F7
|
||||
:10032800130000000324C1001301010167800000CD
|
||||
:10033800130101FD2326810213040103232EA4FCCB
|
||||
:10034800232CB4FC232AC4FCB70701002324F4FEA1
|
||||
:10035800232604FE6F00C0028327C4FE032784FD02
|
||||
:10036800B307F70083C7070013870700832784FEB6
|
||||
:1003780023A0E7008327C4FE938717002326F4FEF3
|
||||
:100388000327C4FE832744FDE348F7FC832744FD85
|
||||
:10039800138507000324C1021301010367800000CD
|
||||
:1003A800130101FD2326810213040103232EA4FC5B
|
||||
:1003B8008327C4FD63D807008327C4FDB307F04033
|
||||
:1003C800232EF4FC0327C4FDB7370000938707806A
|
||||
:1003D80063D8E700B737000093870780232EF4FC23
|
||||
:1003E80083A701C32326F4FE03A701C38327C4FD03
|
||||
:1003F8003307F70023A8E1C28327C4FE138507004B
|
||||
:100408000324C1021301010367800000130101FEE8
|
||||
:10041800232E1100232C8100130401022326A4FE9D
|
||||
:1004280013050000EF00400E130000008320C101F7
|
||||
:10043800032481011301010267800000130101FFF9
|
||||
:100448002326810013040101130000000324C100C6
|
||||
:100458001301010167800000130101FF23268100B9
|
||||
:1004680013040101130000000324C100130101015A
|
||||
:1004780067800000130101FF232611002324810057
|
||||
:1004880013040101EF00C00A930705001385070054
|
||||
:100498008320C1000324810013010101678000004B
|
||||
:1004A800130101FF2326810013040101130000003A
|
||||
:1004B8000324C1001301010167800000130101FF3B
|
||||
:1004C800232681001304010183A781C393861700A3
|
||||
:1004D80023ACD1C2138507000324C1001301010115
|
||||
:1004E80067800000130101FF232681001304010126
|
||||
:1004F800130000000324C1001301010167800000FC
|
||||
:100508006B10B500678000006B0005006780000075
|
||||
:100518006B40B500678000006B2005006780000015
|
||||
:100528006B300000678000007325100267800000B0
|
||||
:100538007325000267800000130540006B0005006A
|
||||
:10054800F32610029396F600732600029315A60070
|
||||
:100558001316260037F1FF6F3301B1403301D14044
|
||||
:100568003301C100F326100263860600130500005C
|
||||
:100578006B00050067800000130101FF23261100AE
|
||||
:10058800232481001304010113051000EFF0DFF7A5
|
||||
:10059800EFF05FB213000000138507008320C1004D
|
||||
:1005A8000324810013010101678000009305050001
|
||||
:1005B8009306000013060000130500006F00C0201A
|
||||
:1005C800130101FF93050000232481002326110055
|
||||
:1005D80013040500EF00C02803A581C28327C503C3
|
||||
:1005E80063840700E780070013050400EFF01FE2AB
|
||||
:1005F800130101FF23248100232291003724008066
|
||||
:10060800B724008093874498130444983304F44033
|
||||
:100618002326110013542440630204029314240077
|
||||
:100628009384C4FFB384F40083A704001304F4FF85
|
||||
:100638009384C4FFE7800700E31804FE8320C10009
|
||||
:100648000324810083244100130101016780000015
|
||||
:10065800130101FF23248100232021013724008076
|
||||
:100668003729008093070498130909983309F9403A
|
||||
:1006780023261100232291001359294063000902FF
|
||||
:10068800130404989304000083270400938414003F
|
||||
:1006980013044400E7800700E31899FE372400801C
|
||||
:1006A8003729008093070498130949983309F940BA
|
||||
:1006B80013592940630009021304049893040000A5
|
||||
:1006C800832704009384140013044400E780070080
|
||||
:1006D800E31899FE8320C10003248100832441008C
|
||||
:1006E8000329010013010101678000001303F000D2
|
||||
:1006F80013070500637EC3029377F7006390070A28
|
||||
:1007080063920508937606FF1376F600B386E60033
|
||||
:100718002320B7002322B7002324B7002326B700DD
|
||||
:1007280013070701E366D7FE63140600678000001D
|
||||
:10073800B306C3409396260097020000B38656007E
|
||||
:100748006780C6002307B700A306B7002306B700D3
|
||||
:10075800A305B7002305B700A304B7002304B70017
|
||||
:10076800A303B7002303B700A302B7002302B7000F
|
||||
:10077800A301B7002301B700A300B7002300B70007
|
||||
:100788006780000093F5F50F93968500B3E5D500D3
|
||||
:1007980093960501B3E5D5006FF0DFF69396270031
|
||||
:1007A80097020000B386560093820000E78006FA9D
|
||||
:1007B80093800200938707FF3307F7403306F6005C
|
||||
:1007C800E378C3F66FF0DFF303A781C283278714AA
|
||||
:1007D800638C070403A747001308F001634EE8067B
|
||||
:1007E8001318270063060502338307012324C3086F
|
||||
:1007F80083A88718130610003316E600B3E8C8006C
|
||||
:1008080023A417192324D310930620006304D502C8
|
||||
:100818001307170023A2E700B387070123A4B70033
|
||||
:1008280013050000678000009307C7142324F714FA
|
||||
:100838006FF05FFA83A6C7181307170023A2E70013
|
||||
:1008480033E6C60023A6C718B387070123A4B70059
|
||||
:1008580013050000678000001305F0FF67800000A3
|
||||
:10086800130101FD2324810103AC81C2232E310130
|
||||
:10087800232C4101232A5101232861012326110237
|
||||
:10088800232481022322910223202103232671019C
|
||||
:10089800930A0500138B0500130A10009309F0FF53
|
||||
:1008A80003298C1463080902832449001384F4FF84
|
||||
:1008B8006342040293942400B304990063040B0474
|
||||
:1008C80083A74410638067051304F4FF9384C4FF6F
|
||||
:1008D800E31634FF8320C1020324810283244102EA
|
||||
:1008E800032901028329C101032A8101832A4101C5
|
||||
:1008F800032B0101832BC100032C81001301010389
|
||||
:10090800678000008327490083A644009387F7FF88
|
||||
:10091800638A870423A20400E38806FA83278918D8
|
||||
:1009280033178A00832B4900B377F700639E0700CB
|
||||
:10093800E780060083274900E39477F783278C1420
|
||||
:10094800E38427F96FF0DFF58327C91883A54408E6
|
||||
:100958003377F700631C070013850A00E780060059
|
||||
:100968006FF05FFD232289006FF01FFB13850500E0
|
||||
:08097800E78006006FF01FFC90
|
||||
:04198000580000808B
|
||||
:1019880000000000741C0080DC1C0080441D0080E6
|
||||
:10199800000000000000000000000000000000003F
|
||||
:1019A800000000000000000000000000000000002F
|
||||
:1019B800000000000000000000000000000000001F
|
||||
:1019C800000000000000000000000000000000000F
|
||||
:1019D80000000000000000000000000000000000FF
|
||||
:1019E80000000000000000000000000000000000EF
|
||||
:1019F80000000000000000000000000000000000DF
|
||||
:101A080000000000000000000000000000000000CE
|
||||
:101A180000000000000000000000000000000000BE
|
||||
:101A280000000000000000000100000000000000AD
|
||||
:101A38000E33CDAB34126DE6ECDE05000B00000072
|
||||
:101A4800000000000000000000000000000000008E
|
||||
:101A5800000000000000000000000000000000007E
|
||||
:101A6800000000000000000000000000000000006E
|
||||
:101A7800000000000000000000000000000000005E
|
||||
:101A8800000000000000000000000000000000004E
|
||||
:101A9800000000000000000000000000000000003E
|
||||
:101AA800000000000000000000000000000000002E
|
||||
:101AB800000000000000000000000000000000001E
|
||||
:101AC800000000000000000000000000000000000E
|
||||
:101AD80000000000000000000000000000000000FE
|
||||
:101AE80000000000000000000000000000000000EE
|
||||
:101AF80000000000000000000000000000000000DE
|
||||
:101B080000000000000000000000000000000000CD
|
||||
:101B180000000000000000000000000000000000BD
|
||||
:101B280000000000000000000000000000000000AD
|
||||
:101B3800000000000000000000000000000000009D
|
||||
:101B4800000000000000000000000000000000008D
|
||||
:101B5800000000000000000000000000000000007D
|
||||
:101B6800000000000000000000000000000000006D
|
||||
:101B7800000000000000000000000000000000005D
|
||||
:101B8800000000000000000000000000000000004D
|
||||
:101B9800000000000000000000000000000000003D
|
||||
:101BA800000000000000000000000000000000002D
|
||||
:101BB800000000000000000000000000000000001D
|
||||
:101BC800000000000000000000000000000000000D
|
||||
:101BD80000000000000000000000000000000000FD
|
||||
:101BE80000000000000000000000000000000000ED
|
||||
:101BF80000000000000000000000000000000000DD
|
||||
:101C080000000000000000000000000000000000CC
|
||||
:101C180000000000000000000000000000000000BC
|
||||
:101C280000000000000000000000000000000000AC
|
||||
:101C3800000000000000000000000000000000009C
|
||||
:101C4800000000000000000000000000000000008C
|
||||
:101C5800000000000000000000000000000000007C
|
||||
:101C6800000000000000000000000000000000006C
|
||||
:101C7800000000000000000000000000000000005C
|
||||
:101C8800000000000000000000000000000000004C
|
||||
:101C9800000000000000000000000000000000003C
|
||||
:101CA800000000000000000000000000000000002C
|
||||
:101CB800000000000000000000000000000000001C
|
||||
:101CC800000000000000000000000000000000000C
|
||||
:101CD80000000000000000000000000000000000FC
|
||||
:101CE80000000000000000000000000000000000EC
|
||||
:101CF80000000000000000000000000000000000DC
|
||||
:101D080000000000000000000000000000000000CB
|
||||
:101D180000000000000000000000000000000000BB
|
||||
:101D280000000000000000000000000000000000AB
|
||||
:101D3800000000000000000000000000000000009B
|
||||
:101D4800000000000000000000000000000000008B
|
||||
:101D5800000000000000000000000000000000007B
|
||||
:101D6800000000000000000000000000000000006B
|
||||
:101D7800000000000000000000000000000000005B
|
||||
:101D8800000000000000000000000000000000004B
|
||||
:101D9800000000000000000000000000000000003B
|
||||
:081DA800000000000000000033
|
||||
:101DB0008819008000000070000000100000002062
|
||||
:040000058000000077
|
||||
:00000001FF
|
||||
@@ -27,12 +27,7 @@ _start:
|
||||
jal vx_set_sp
|
||||
li a0, 1
|
||||
.word 0x0005006b # tmc 1
|
||||
# Initialize global pointer
|
||||
.option push
|
||||
.option norelax
|
||||
1:auipc gp, %pcrel_hi(__global_pointer$)
|
||||
addi gp, gp, %pcrel_lo(1b)
|
||||
.option pop
|
||||
# Initialize global pointerp
|
||||
# call __cxx_global_var_init
|
||||
# Clear the bss segment
|
||||
la a0, _edata
|
||||
@@ -55,6 +50,12 @@ _start:
|
||||
vx_set_sp:
|
||||
li a0, 4
|
||||
.word 0x0005006b # tmc 4
|
||||
|
||||
.option push
|
||||
.option norelax
|
||||
1:auipc gp, %pcrel_hi(__global_pointer$)
|
||||
addi gp, gp, %pcrel_lo(1b)
|
||||
.option po
|
||||
|
||||
csrr a3, 0x21 # get wid
|
||||
slli a3, a3, 0x1a # shift by wid
|
||||
|
||||
@@ -40,23 +40,50 @@ void vx_spawnWarps(unsigned numWarps, unsigned numThreads, func_t func_ptr, void
|
||||
|
||||
}
|
||||
|
||||
void pocl_spawn(context_t * ctx, const void * pfn, void * arguments)
|
||||
|
||||
uint8_t * pocl_args;
|
||||
uint8_t * pocl_ctx;
|
||||
vx_pocl_workgroup_func pocl_pfn;
|
||||
|
||||
|
||||
void pocl_spawn_real()
|
||||
{
|
||||
vx_tmc(4);
|
||||
int x = vx_threadID();
|
||||
int y = vx_warpID();
|
||||
(pocl_pfn)( pocl_args, pocl_ctx, x, y, 0);
|
||||
|
||||
if (y != 0)
|
||||
{
|
||||
vx_tmc(0);
|
||||
}
|
||||
vx_tmc(1);
|
||||
}
|
||||
|
||||
|
||||
void pocl_spawn(struct context_t * ctx, const void * pfn, void * arguments)
|
||||
{
|
||||
|
||||
vx_pocl_workgroup_func use_pfn = (vx_pocl_workgroup_func) pfn;
|
||||
int z;
|
||||
int y;
|
||||
int x;
|
||||
for (z = 0; z < ctx->num_groups[2]; ++z)
|
||||
{
|
||||
for (y = 0; y < ctx->num_groups[1]; ++y)
|
||||
{
|
||||
for (x = 0; x < ctx->num_groups[0]; ++x)
|
||||
{
|
||||
(use_pfn)((uint8_t *)arguments, (uint8_t *)ctx, x, y, z);
|
||||
}
|
||||
}
|
||||
}
|
||||
pocl_pfn = (vx_pocl_workgroup_func) pfn;
|
||||
pocl_ctx = (uint8_t *) ctx;
|
||||
pocl_args = (uint8_t *) arguments;
|
||||
|
||||
|
||||
pocl_spawn_real();
|
||||
|
||||
// int z;
|
||||
// int y;
|
||||
// int x;
|
||||
// for (z = 0; z < ctx->num_groups[2]; ++z)
|
||||
// {
|
||||
// for (y = 0; y < ctx->num_groups[1]; ++y)
|
||||
// {
|
||||
// for (x = 0; x < ctx->num_groups[0]; ++x)
|
||||
// {
|
||||
// (use_pfn)((uint8_t *)arguments, (uint8_t *)ctx, x, y, z);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
@@ -49,7 +49,7 @@ typedef void (*vx_pocl_workgroup_func) (uint8_t * /* args */,
|
||||
uint32_t /* group_y */,
|
||||
uint32_t /* group_z */);
|
||||
|
||||
void pocl_spawn(context_t * ctx, const void * pfn, void * arguments);
|
||||
void pocl_spawn(struct context_t * ctx, const void * pfn, void * arguments);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user