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

Improve perf by using less heap allocs #37

Merged
merged 3 commits into from
Jul 7, 2024

Conversation

rozukke
Copy link
Contributor

@rozukke rozukke commented Jul 7, 2024

As stated. Should improve perf by small margin.

@rozukke rozukke requested a review from nhatdongdang July 7, 2024 13:17
src/main.c Outdated Show resolved Hide resolved
src/main.c Outdated Show resolved Hide resolved
Copy link
Collaborator

@nhatdongdang nhatdongdang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The current matrix multiplication implementation loops through 104 rows instead of 98, and 72 rows instead of 65 rows. To ensure the safety and correctness of the output, the sizes of the output array should be adjusted to 104 and 72 respectively.

@rozukke rozukke requested a review from nhatdongdang July 7, 2024 13:39
Copy link
Collaborator

@nhatdongdang nhatdongdang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@nhatdongdang nhatdongdang merged commit e5d2909 into kachi-group:main Jul 7, 2024
2 checks passed
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

Successfully merging this pull request may close these issues.

2 participants