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

Compilation for Python programs with tracing enabled fails #2398

Open
cmnrd opened this issue Aug 9, 2024 · 0 comments
Open

Compilation for Python programs with tracing enabled fails #2398

cmnrd opened this issue Aug 9, 2024 · 0 comments
Labels
bug Something isn't working python Related to the Python target

Comments

@cmnrd
Copy link
Collaborator

cmnrd commented Aug 9, 2024

When I compile test/Python/src/HelloWorld.lf, I get the following error with gcc 14:

test/Python/src-gen/HelloWorld/trace/impl/src/trace_impl.c: In function ‘start_trace’:
test/Python/src-gen/HelloWorld/trace/impl/src/trace_impl.c:155:57: error: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument [-Werror=calloc-transposed-args]
  155 |   trace->_lf_trace_buffer_size = (size_t*)calloc(sizeof(size_t), trace->_lf_number_of_trace_buffers + 1);
      |                                                         ^~~~~~
test/Python/src-gen/HelloWorld/trace/impl/src/trace_impl.c:155:57: note: earlier argument should specify number of elements, later size of each element
cc1: all warnings being treated as errors

This error disappears when I disable tracing. BTW, why does the HelloWorld test (which should be minimal) use tracing?

@cmnrd cmnrd added bug Something isn't working python Related to the Python target labels Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working python Related to the Python target
Projects
None yet
Development

No branches or pull requests

1 participant