mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 04:30:23 +00:00
Changed printValue() to print constant value if the value is a constant.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@292 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
683847fb75
commit
b2d11bad7e
@ -1,11 +1,14 @@
|
||||
|
||||
#include "llvm/Analysis/LiveVar/ValueSet.h"
|
||||
#include "llvm/ConstPoolVals.h"
|
||||
|
||||
|
||||
void printValue( const Value *const v) // func to print a Value
|
||||
{
|
||||
if( (*v).hasName() ) cout << v << "(" << ((*v).getName()) << ") ";
|
||||
//if( (*v).hasName() ) cout << ((*v).getName()) << " ";
|
||||
else if (v->getValueType() == Value::ConstantVal) // if const
|
||||
cout << v << "(" << ((ConstPoolVal *) v)->getStrValue() << ") ";
|
||||
else cout << v << " ";
|
||||
}
|
||||
|
||||
|
@ -1,11 +1,14 @@
|
||||
|
||||
#include "llvm/Analysis/LiveVar/ValueSet.h"
|
||||
#include "llvm/ConstPoolVals.h"
|
||||
|
||||
|
||||
void printValue( const Value *const v) // func to print a Value
|
||||
{
|
||||
if( (*v).hasName() ) cout << v << "(" << ((*v).getName()) << ") ";
|
||||
//if( (*v).hasName() ) cout << ((*v).getName()) << " ";
|
||||
else if (v->getValueType() == Value::ConstantVal) // if const
|
||||
cout << v << "(" << ((ConstPoolVal *) v)->getStrValue() << ") ";
|
||||
else cout << v << " ";
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user