Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding -DNDEBUG flag will cause the helloworld example to crash #705

Closed
renzibei opened this issue Oct 24, 2022 · 2 comments
Closed

Adding -DNDEBUG flag will cause the helloworld example to crash #705

renzibei opened this issue Oct 24, 2022 · 2 comments

Comments

@renzibei
Copy link
Contributor

Hello, I find that if -DNDEBUG flag is added to the compile-options, the helloworld example will crash. After the modification, the CFLAGS line in the Makefile file becomes

CFLAGS += -O -DNDEBUG -gdwarf-2 $(shell $(PKGCONF) --cflags libdpdk)

And when I running the helloworld program, it will crashes or print many lines of unknown event: 00000000.

Can you help look into the reason of it?

@renzibei renzibei changed the title Add -DNDEBUG flag will cause the helloworld example to crash Adding -DNDEBUG flag will cause the helloworld example to crash Oct 24, 2022
@renzibei
Copy link
Contributor Author

I used the compiled static library of f-stack. Maybe the status of NDEBUG macro in the header files of f-stack codes will affect the ABI stability?

@jfb8856606
Copy link
Contributor

Fixed.
Because assert((kq = ff_kqueue()) > 0); was be ignored and nevents used usigned type.

anvayabn pushed a commit to anvayabn/f-stack that referenced this issue Jul 13, 2023
…ld example

to crash. Because `assert((kq = ff_kqueue()) > 0);` was be ignored and
nevents used usigned type.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants