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

Remove setup_core_to_tlb_map #403

Merged
merged 7 commits into from
Dec 17, 2024
Merged

Remove setup_core_to_tlb_map #403

merged 7 commits into from
Dec 17, 2024

Conversation

broskoTT
Copy link
Contributor

@broskoTT broskoTT commented Dec 16, 2024

Issue

Related to #44 but also on a path of #351

Description

This function in API is a surplus. All the info is already available to the Cluster class through configure_tlb calls.
This is initial PR which changes the API. The following PR won't change the API but will restructure functions internally to introduce TLBManager class.

List of the changes

  • Removed setup_core_to_tlb_map. Fill up the same internal structure through configure_tlb api
  • tlbs_init_per_chip is also unnecessary
  • Extracted the logic for checking whether static tlb is setup

Testing

Covered through existing tests.

API Changes

This PR has API changes:

Copy link
Contributor

@pjanevskiTT pjanevskiTT left a comment

Choose a reason for hiding this comment

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

Nice. One thing, which probably wasn't working even before your change, is calling configure_tlb twice for different cores and the same index, so some of our maps will have two cores pointing to the same index, which obviously is not correct. That is why there was a requirement that mapping function is 1:1 I guess. Per offline discussion, open an issue on this and maybe leave a comment somewhere to fix this. This problem will go away with some kind of TLB manager, but it would be nice just to be aware of this problem right now

@broskoTT broskoTT added the changes api API changing PR, needs changes in client code label Dec 17, 2024
@broskoTT broskoTT force-pushed the brosko/core_to_tlb_map branch from 96ed817 to 00169c2 Compare December 17, 2024 12:57
@broskoTT broskoTT merged commit bfbb7e9 into main Dec 17, 2024
21 of 24 checks passed
@broskoTT broskoTT deleted the brosko/core_to_tlb_map branch December 17, 2024 15:46
broskoTT added a commit to tenstorrent/tt-metal that referenced this pull request Dec 17, 2024
### Ticket
Related to #13948

### Problem description
This API call is unnecessary since all the needed information is already
passed during "configure_tlb" calls.
Related to tenstorrent/tt-umd#403

### What's changed
- setup_core_to_tlb_map is removed, functionality should stay the same

### Checklist
- [x] All post-commit tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376643291
- [ ] Blackhole post-commit tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376645486
- [x] (Single-card) Model perf tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376647574
- [x] (Single-card) Device perf regressions :
https://github.com/tenstorrent/tt-metal/actions/runs/12376649607
- [ ] (T3K) T3000 unit tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376651625
- [ ] (T3K) T3000 demo tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376653954
- [ ] (TG) TG unit tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376656331
- [ ] (TG) TG demo tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376658168
- [ ] (TGG) TGG unit tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376660071
- [x] (TGG) TGG demo tests :
https://github.com/tenstorrent/tt-metal/actions/runs/12376661988
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changes api API changing PR, needs changes in client code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants