opentitan icon indicating copy to clipboard operation
opentitan copied to clipboard

[dv/dpi] TCP server enters infinite loop if ring buffer is full

Open duk-37 opened this issue 5 months ago • 2 comments

Description

The rptr and wptr variables here are missing volatile, so GCC will optimize the while loop in tcp_server_put_byte to a branch and an infinite loop when compiling with -O2. as you can see in this godbolt link.

duk-37 avatar Sep 21 '24 01:09 duk-37