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

i#6662 public traces, part 9: TLB simulator with v2p #6961

Merged
merged 55 commits into from
Sep 18, 2024

Conversation

edeiana
Copy link
Contributor

@edeiana edeiana commented Aug 31, 2024

We want to provide a virtual to physical mapping for
the release of public traces to be used with our TLB
simulator.
We enable the TLB simulator to operate on the physical
addresses provided by a v2p.textproto file, which is
read by the previously added v2p_reader.

Adds an end-to-end test "tool.drcacheoff.tlb_simulator_v2p"
and a v2p.textproto mapping to
clients/drcachesim/tests/drmemtrace.threadsig.aarch64.raw.

Adds unit tests to check that the addresses used by the TLB
simulator are the actual physical ones.

Issue #6662

edeiana added 13 commits August 21, 2024 00:58
Implementation of a simple reader for virtual to
physical address mapping in textproto format.
The reader parses blocks in the following form:
address_mapping {
    virtual_address: 0x123
    physical_address: 0x3
}
present in the provided textproto file to create a
map in memory from virtual to physical address.

Adds unit tests and a sample v2p textproto file
to check the correctness of the generated map.

Issue #6662
These info, along with v2p_map, is now grouped together in v2p_info_t.
We want to provide a virtual to physical mapping for
the release of public traces to be used with our TLB
simulator.
We enable the TLB simulator to operate on the physical
addresses provided by a v2p.textproto file, which is
read by the previously added v2p_reader.

Issue #6662
@edeiana
Copy link
Contributor Author

edeiana commented Sep 15, 2024

Requesting re-review to double check my logic on page_size and the newly added unit test.

Right now we have 3 possible page sizes:

  1. in simulator_t, set by the page size marker in the trace;
  2. in tlb_simulator_r, it's a knob set by the user;
  3. in v2p.textproto, if the user uses the virtual to physical mapping.

If we are in case 3. that page size overwrites 1. and 2.. Should we have a warning or an error if for 2. the user sets a different page size while still wanting to use v2p.textproto?

Improved this option description in -help, clarifying that -use_physical
must be used in order for v2p.textproto to be used.
api/docs/release.dox Show resolved Hide resolved
api/docs/release.dox Outdated Show resolved Hide resolved
api/docs/release.dox Outdated Show resolved Hide resolved
clients/drcachesim/analyzer_multi.cpp Outdated Show resolved Hide resolved
clients/drcachesim/common/options.cpp Outdated Show resolved Hide resolved
clients/drcachesim/tests/tlb_simulator_unit_test.h Outdated Show resolved Hide resolved
clients/drcachesim/tests/tlb_simulator_unit_test.cpp Outdated Show resolved Hide resolved
clients/drcachesim/tests/tlb_simulator_unit_test.cpp Outdated Show resolved Hide resolved
@edeiana edeiana merged commit fd99b5e into master Sep 18, 2024
17 checks passed
@edeiana edeiana deleted the i6662-v2p-tlb-simulator branch September 18, 2024 23:47
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