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

prog: TestIsComplexPtr fails when run without -short #5300

Open
a-nogikh opened this issue Sep 11, 2024 · 3 comments
Open

prog: TestIsComplexPtr fails when run without -short #5300

a-nogikh opened this issue Sep 11, 2024 · 3 comments
Labels

Comments

@a-nogikh
Copy link
Collaborator

any_test.go:65: generated too few complex types: 1060/1611

Mostly it failed to generate the autogenerated types, e.g.

        any_test.go:61: did not generate netlink_msg_t[autogenerated_netlink, genlmsghdr, fw_policy$auto_cls_fw]
        any_test.go:61: did not generate netlink_msg_t[autogenerated_netlink, genlmsghdr, nft_bitwise_policy$auto_nft_bitwise]
        any_test.go:61: did not generate netlink_msg_t[autogenerated_netlink, genlmsghdr, nft_match_policy$auto_nft_compat]
        any_test.go:61: did not generate netlink_msg_t[autogenerated_netlink, genlmsghdr, dcbnl_bcn_nest$auto_dcbnl]
        any_test.go:61: did not generate netlink_msg_t[autogenerated_netlink, genlmsghdr, devlink_dl_port_function_nl_policy$auto_netlink_gen]
        any_test.go:61: did not generate netlink_msg_t[autogenerated_netlink, genlmsghdr, ifa_phonet_policy$auto_pn_netlink]
        any_test.go:61: did not generate netlink_msg_t[autogenerated_netlink, genlmsghdr, vni_filter_policy$auto_vxlan_vnifilter]

Cc @dvyukov

@a-nogikh a-nogikh added the bug label Sep 11, 2024
@dvyukov
Copy link
Collaborator

dvyukov commented Sep 11, 2024

These types are effectively unused, we only reference then in the sendmsg$autorun syscall only to prevent unused warnings. It references dozens on policies, so there is no chance to generate them all in 10 attempts.

I think the proper fix is to not generate these unused policies (for now, while they are not used for real).
A hacky fix is to not test auto-generated ones, or special case sendmsg$autorun or auto_union.

@a-nogikh
Copy link
Collaborator Author

@pimyn-girgis do we actually still need sendmsg$autorun?

@pimyn-girgis
Copy link
Collaborator

pimyn-girgis commented Sep 11, 2024

I think the proper fix is to not generate these unused policies (for now, while they are not used for real).

do we actually still need sendmsg$autorun?

The only benefit in keeping unused policies is that it makes it more obvious how syz-declextract descriptions change over time, and might help in catching bugs between different versions. Other than that, I do not see any need to keep them.

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

No branches or pull requests

3 participants