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

Deal with technical debt in the kernel #1589

Closed
8 tasks done
hannobraun opened this issue Feb 15, 2023 · 11 comments
Closed
8 tasks done

Deal with technical debt in the kernel #1589

hannobraun opened this issue Feb 15, 2023 · 11 comments
Assignees
Labels
topic: core Issues relating to core geometry, operations, algorithms type: planning Issues about project planning

Comments

@hannobraun
Copy link
Owner

hannobraun commented Feb 15, 2023

Over the last months, I have added quite a bit of unnecessary complexity to the kernel. In some cases, I knew it was unnecessary, but couldn't think of a simpler solution at the time. In other cases, I thought the complexity was just inherent to the problems I was trying to solve. This complexity has turned into a real problem. It hinders every non-trivial change I'm trying to make in the kernel, and caused progress in that area to slow to a crawl.

By now, I have both recognized that a lot of the complexity that I thought necessary is in fact unnecessary, and thought of solutions to reduce it. I have already opened quite a few issues meant to address it, and will open more as I gain new insights. This issue is meant as a central place to track and coordinate these efforts.

Here's the list of issues:

I will keep this list updated going forward.

These issues are closely related, and it will probably not be practical to address most of them in isolation. This is because the very complexity that they aim to address tends to hinder the necessary cleanup efforts. Most likely, I will try to pick low-hanging fruit from each of them, reducing the overall complexity each time, and making more low-hanging fruit available. This will hopefully allow me to address them in incremental steps, without being forced into too big of a rewrite.

@hannobraun
Copy link
Owner Author

#1588 has been addressed. I've updated the list in the issue description.

Finally something that was easier than expected!

@hannobraun
Copy link
Owner Author

Added #1605 to the list.

@hannobraun
Copy link
Owner Author

#1605 is done! List updated.

@hannobraun
Copy link
Owner Author

I've made some progress on #1525. See the update I posted there: #1525 (comment)

@hannobraun
Copy link
Owner Author

Added #1634.

@hannobraun
Copy link
Owner Author

#1634 and #1525 are done! List updated.

I think the most promising next step is #1586, which I'll be looking into next. Although I'll keep my eyes peeled for more opportunities to simplify things, which might mean more issues being added to the list.

@hannobraun
Copy link
Owner Author

I had another idea. Added #1643 to the list.

@hannobraun
Copy link
Owner Author

And #1643 is done already. List updated.

This was both surprisingly easy, and surprisingly effective. Almost 300 lines of code removed!

@hannobraun
Copy link
Owner Author

And #1586 is also done. List updated.

Very productive day!

@hannobraun
Copy link
Owner Author

#1570 is now also done (list has been updated), which takes care of all remaining items on the list!

I have some more ideas on what could be improved that I want to follow up on, but those are just some weak notions that might come to nothing. Most likely, I will at most land some more pull requests that clean up some smaller stuff. I might open more issues and add those to the list, but I don't expect that.

One way or another though, I won't spend much more time on this issue. The improvement so far has been massive, and I think it's time to move on to other opportunities.

@hannobraun
Copy link
Owner Author

Okay, it's time to declare victory. I'm done!

I've merged two more pull requests, cleaning up the builder API (#1692, #1693). I've also opened one more issue (#1691) that I could add to the list here, but I decided not to. First, it's not critical and doesn't need to happen now. Second, I'm not sure about the solution, so it makes sense to let that hang around the back of my mind for a bit anyway.

I'm really happy with how this cleanup turned out! In aggregate, it's been a huge improvement. The kernel code has reached a level of simplicity that it hasn't had in many months. And back then, it had fewer features and was much more riddled with bugs, so I think that's a clear win.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: core Issues relating to core geometry, operations, algorithms type: planning Issues about project planning
Projects
None yet
Development

No branches or pull requests

1 participant