diff options
author | Chris Lattner <sabre@nondot.org> | 2002-10-28 01:16:38 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2002-10-28 01:16:38 +0000 |
commit | 6b9445389a226b4ac97ceb89a34ee1a5bf921714 (patch) | |
tree | 2e57ff4d376ea97bfccbef29486305449142d47d /lib/CodeGen/MachineFunction.cpp | |
parent | e05c8fd5dd4f704c3aea352161b94baaa24b263b (diff) |
Minor cleanups
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4312 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/MachineFunction.cpp')
-rw-r--r-- | lib/CodeGen/MachineFunction.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/lib/CodeGen/MachineFunction.cpp b/lib/CodeGen/MachineFunction.cpp index 39fa913015..4d680754d0 100644 --- a/lib/CodeGen/MachineFunction.cpp +++ b/lib/CodeGen/MachineFunction.cpp @@ -1,13 +1,13 @@ -//===-- MachineCodeForMethod.cpp -------------------------------------------=// +//===-- MachineFunction.cpp -----------------------------------------------===// // -// Purpose: -// Collect native machine code information for a function. -// This allows target-specific information about the generated code -// to be stored with each function. -//===---------------------------------------------------------------------===// +// Collect native machine code information for a function. This allows +// target-specific information about the generated code to be stored with each +// function. +// +//===----------------------------------------------------------------------===// -#include "llvm/CodeGen/MachineFunction.h" #include "llvm/CodeGen/MachineInstr.h" // For debug output +#include "llvm/CodeGen/MachineFunction.h" #include "llvm/CodeGen/MachineCodeForBasicBlock.h" #include "llvm/CodeGen/MachineCodeForInstruction.h" #include "llvm/Target/TargetMachine.h" @@ -228,8 +228,7 @@ MachineFunction::allocateLocalVar(const TargetMachine& target, if (offset == INVALID_FRAME_OFFSET) { unsigned int getPaddedSize; - offset = this->computeOffsetforLocalVar(target, val, getPaddedSize, - sizeToUse); + offset = computeOffsetforLocalVar(target, val, getPaddedSize, sizeToUse); offsets[val] = offset; incrementAutomaticVarsSize(getPaddedSize); } @@ -291,7 +290,7 @@ int MachineFunction::getOffset(const Value* val) const { hash_map<const Value*, int>::const_iterator pair = offsets.find(val); - return (pair == offsets.end())? INVALID_FRAME_OFFSET : pair->second; + return (pair == offsets.end()) ? INVALID_FRAME_OFFSET : pair->second; } void @@ -302,7 +301,8 @@ MachineFunction::dump() const for (Function::const_iterator BB = method->begin(); BB != method->end(); ++BB) { - std::cerr << std::endl << (*BB).getName() << " (" << (const void*) BB << ")" << ":" << std::endl; + std::cerr << "\n" << BB->getName() << " (" << (const void*)BB + << ")" << ":" << "\n"; MachineCodeForBasicBlock& mvec = MachineCodeForBasicBlock::get(BB); for (unsigned i=0; i < mvec.size(); i++) std::cerr << "\t" << *mvec[i]; |