Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
llvm-epi-0.8
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Roger Ferrer
llvm-epi-0.8
Commits
faa42d26
Commit
faa42d26
authored
21 years ago
by
Misha Brukman
Browse files
Options
Downloads
Patches
Plain Diff
We accept TargetMachine as a const reference.
llvm-svn: 9775
parent
bd4a8ed1
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
llvm/lib/Target/Sparc/PeepholeOpts.cpp
+3
-3
3 additions, 3 deletions
llvm/lib/Target/Sparc/PeepholeOpts.cpp
with
3 additions
and
3 deletions
llvm/lib/Target/Sparc/PeepholeOpts.cpp
+
3
−
3
View file @
faa42d26
...
@@ -112,7 +112,7 @@ class PeepholeOpts: public BasicBlockPass {
...
@@ -112,7 +112,7 @@ class PeepholeOpts: public BasicBlockPass {
bool
visit
(
MachineBasicBlock
&
mvec
,
bool
visit
(
MachineBasicBlock
&
mvec
,
MachineBasicBlock
::
iterator
BBI
)
const
;
MachineBasicBlock
::
iterator
BBI
)
const
;
public:
public:
PeepholeOpts
(
const
TargetMachine
&
T
)
:
target
(
T
)
{
}
PeepholeOpts
(
const
TargetMachine
&
T
M
)
:
target
(
T
M
)
{
}
bool
runOnBasicBlock
(
BasicBlock
&
BB
);
// apply this pass to each BB
bool
runOnBasicBlock
(
BasicBlock
&
BB
);
// apply this pass to each BB
virtual
const
char
*
getPassName
()
const
{
return
"Peephole Optimization"
;
}
virtual
const
char
*
getPassName
()
const
{
return
"Peephole Optimization"
;
}
};
};
...
@@ -160,6 +160,6 @@ bool PeepholeOpts::runOnBasicBlock(BasicBlock &BB) {
...
@@ -160,6 +160,6 @@ bool PeepholeOpts::runOnBasicBlock(BasicBlock &BB) {
// createPeepholeOptsPass - Public entrypoint for peephole optimization
// createPeepholeOptsPass - Public entrypoint for peephole optimization
// and this file as a whole...
// and this file as a whole...
//
//
FunctionPass
*
createPeepholeOptsPass
(
TargetMachine
&
T
)
{
FunctionPass
*
createPeepholeOptsPass
(
const
TargetMachine
&
T
M
)
{
return
new
PeepholeOpts
(
T
);
return
new
PeepholeOpts
(
T
M
);
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment