Skip to content
This repository has been archived by the owner on Apr 13, 2019. It is now read-only.

FreeRTOS singlestep issue #173

Open
arunthomas opened this issue Oct 11, 2018 · 0 comments
Open

FreeRTOS singlestep issue #173

arunthomas opened this issue Oct 11, 2018 · 0 comments

Comments

@arunthomas
Copy link
Contributor

I have been experimenting with SiFive's FreeRTOS demo application: https://github.com/sifive/freedom-e-sdk/tree/FreeRTOS

When I run the demo on QEMU without singlestep, the demo runs successfully:

qemu-system-riscv32 -machine sifive_e -nographic -kernel RISCV_HiFive1_GCC.elf

Sending to queue
Recieved: 100
Sending to queue
Recieved: 100
Sending to queue
Recieved: 100
Sending to queue
Recieved: 100
Giving Semaphore
RTOS Timer Callback
Semaphore taken
...

When I enable '-singlestep', the demo fails:

qemu-system-riscv32 -machine sifive_e -nographic -kernel RISCV_HiFive1_GCC.elf -singlestep

Giving Semaphore
Giving Semaphore
Giving Semaphore
Giving Semaphore
Giving Semaphore
...

I have reproduced the issue with QEMU built from the riscv-all branch. I built FreeRTOS with a recent 32-bit riscv-gnu-toolchain (--with-arch=rv32g --with-abi=ilp32) built from master.

I built FreeRTOS by cloning https://github.com/sifive/freedom-e-sdk/tree/FreeRTOS. I made the following modifications to software/FreeRTOSv9.0.0/Demo/RISCV_HiFive1_GCC/Makefile.inc:

  • Set CC_PATH to point to my toolchain bin dir
  • Modified TARGET to be riscv32-unknown-elf

I build FreeRTOS using:

make -C freedom-e-sdk/software/FreeRTOSv9.0.0/Demo/RISCV_HiFive1_GCC

The FreeRTOS demo code can be found here: https://github.com/sifive/freedom-e-sdk/blob/FreeRTOS/software/FreeRTOSv9.0.0/Demo/RISCV_HiFive1_GCC/main.c

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant