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

Fix missing tracing around load/store and move opt passes #40

Open
wants to merge 1 commit into
base: nanomips
Choose a base branch
from

Conversation

cme
Copy link

@cme cme commented Jan 31, 2024

The move optimisation and load/store optimisation passes were not initialised correctly and so didn't show up in IR dumps with -print-before-all / -print-after-all etc.

@@ -62,6 +62,8 @@ extern "C" LLVM_EXTERNAL_VISIBILITY void LLVMInitializeMipsTarget() {
initializeMipsPreLegalizerCombinerPass(*PR);
initializeNMOptimizeJumpTablesPass(*PR);
initializeRedundantCopyEliminationPass(*PR);
initializeNMLoadStoreOptPass(*PR);

Choose a reason for hiding this comment

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

How did we previously register the pass with pass manager? Do you need to remove that?

Copy link
Author

Choose a reason for hiding this comment

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

It was not explicitly registered, which was the problem. It was just created and added in the MipsPassConfig::addPreSched2() -- so it was run, but otherwise the pass manager didn't know about it.

Copy link

@draganmladjenovic draganmladjenovic left a comment

Choose a reason for hiding this comment

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

LGTM

@djtodoro
Copy link
Collaborator

djtodoro commented Jun 4, 2024

@cme Can we merge this?

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.

3 participants