Skip to content

Reduce size of compiled tests #1442

@ZiaCheemaGit

Description

✗ FAILED: I-andi-00.sig
  Output: work/single_cycle_rv32i_core/build/rv32i/I/I-andi-00.sig.elf
  Error output:
    /home/zia-cheema/Desktop/git-clones/riscv64-elf-ubuntu-22.04-gcc/riscv/riscv64-unknown-elf/bin/ld: /home/zia-cheema/Desktop/git-clones/riscv-arch-test-act4/work/single_cycle_rv32i_core/build/rv32i/I/I-andi-00.sig.elf section `.text' will not fit in region `ROM'
    /home/zia-cheema/Desktop/git-clones/riscv64-elf-ubuntu-22.04-gcc/riscv/riscv64-unknown-elf/bin/ld: /home/zia-cheema/Desktop/git-clones/riscv-arch-test-act4/work/single_cycle_rv32i_core/build/rv32i/I/I-andi-00.sig.elf section `.data' will not fit in region `RAM'
    /home/zia-cheema/Desktop/git-clones/riscv64-elf-ubuntu-22.04-gcc/riscv/riscv64-unknown-elf/bin/ld: section .data VMA [00002000,00018cdf] overlaps section .text VMA [00000000,00003fff]
    /home/zia-cheema/Desktop/git-clones/riscv64-elf-ubuntu-22.04-gcc/riscv/riscv64-unknown-elf/bin/ld: region `ROM' overflowed by 15104 bytes
    /home/zia-cheema/Desktop/git-clones/riscv64-elf-ubuntu-22.04-gcc/riscv/riscv64-unknown-elf/bin/ld: region `RAM' overflowed by 91656 bytes
    /home/zia-cheema/Desktop/git-clones/riscv64-elf-ubuntu-22.04-gcc/riscv/riscv64-unknown-elf/bin/ld: warning: cannot find entry symbol _start; defaulting to 00000000
    collect2: error: ld returned 1 exit status
  Reproduce with:
    /home/zia-cheema/Desktop/git-clones/riscv64-elf-ubuntu-22.04-gcc/riscv/bin/riscv64-unknown-elf-gcc \
      -I/home/zia-cheema/Desktop/git-clones/riscv-arch-test-act4/config/cores/my_cpu/rv32i \
      -T/home/zia-cheema/Desktop/git-clones/riscv-arch-test-act4/config/cores/my_cpu/rv32i/link.ld \
      -O0 \
      -g \
      -mcmodel=medany \
      -nostdlib \
      -I/home/zia-cheema/Desktop/git-clones/riscv-arch-test-act4/tests/env \
      -Wl,--no-warn-rwx-segments \
      -o /home/zia-cheema/Desktop/git-clones/riscv-arch-test-act4/work/single_cycle_rv32i_core/build/rv32i/I/I-andi-00.sig.elf \
      -march=rv32i_zicsr \
      -mabi=ilp32 \
      -DSIGNATURE \
      -DXLEN=32 \
      -DTEST_FLEN=32 \
      /home/zia-cheema/Desktop/git-clones/riscv-arch-test-act4/tests/rv32i/I/I-andi-00.S

✗ Build failed: 1 failed
make: *** [Makefile:168: elfs] Error 1
zia-cheema@zia-cheema-HP-EliteBook-840-G3:~/Desktop/git-clones/riscv-arch-test-act4$ 

I have to run ACTs on an RV32I. My core doesn't yet have csr and fence instructions implemented. I plan to implement those instructions but at a later stage in project timeline. Can't I run tests without them.
Also I have memory constraints. This above output is what I got after I ran make assuming csr is implemented, to atleast see generated tests, why is csr necessary.

Is this memory insufficient for just a single test or all tests. Are there any work arounds for this situation?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions