Various minor cleanup. Get rid of those annoying extra newlines in Linux.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@474 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
arcum42 2009-02-11 13:25:17 +00:00
parent 8630529f8e
commit fd4f5bab0b
14 changed files with 38 additions and 31 deletions

View File

@ -577,6 +577,7 @@ __forceinline u32 gsRead32(u32 mem)
__forceinline u64 gsRead64(u32 mem)
{
// fixme - PS2GS_BASE(mem+4) = (g_RealGSMem+(mem + 4 & 0x13ff))
GIF_LOG("GS read 64 from %8.8lx value: %8.8lx_%8.8lx\n", mem, *(u32*)PS2GS_BASE(mem+4), *(u32*)PS2GS_BASE(mem) );
return *(u64*)PS2GS_BASE(mem);
}
@ -854,7 +855,7 @@ void RunGSState( gzLoadingState& f )
list<GSStatePacket>::iterator it = packets.begin();
g_SaveGSStream = 3;
int skipfirst = 1;
//int skipfirst = 1;
// first extract the data
while(1) {

View File

@ -189,11 +189,6 @@ void mpeg2_idct_init ();
#ifdef _MSC_VER
#define BigEndian(out, in) out = _byteswap_ulong(in)
#else
//#define BigEndian(out, in) \
// __asm__(".intel_syntax\n" \
// "bswap %0\n" \
// ".att_syntax\n" : "=r"(out) : "0"(in) )
#define BigEndian(out, in) \
out = (((((in) >> 24) & 0xFF) << 0) + ((((in) >> 16) & 0xFF) << 8) + \
((((in) >> 8) & 0xFF) << 16) + ((((in) >> 0) & 0xFF) << 24));

View File

@ -329,6 +329,8 @@ void psxMemWrite32(u32 mem, u32 value)
// TLB functions
#ifdef TLB_DEBUG_MEM
// fixme - there are a few places in the code where this is called that really shouldn't receive null.
// cdvdReadSector in CDVD.cpp, psxDma3 in CdRom.cpp, to name two.
void* PSXM(u32 mem)
{
return (psxMemRLUT[(mem) >> 16] == 0 ? NULL : (void*)(psxMemRLUT[(mem) >> 16] + ((mem) & 0xffff)));

View File

@ -20,15 +20,15 @@
#define COLOR_RESET "\033[0m"
// Linux Note : The Linux Console is pretty simple. It just dumps to the stdio!
// (no console open/close/title stuff tho, so those functions are dummies)
// Fixme - A lot of extra \ns are being added in here somewhere. I think it's
// partially in SetColor/ClearColor, as colored lines have more extra \ns then the other
// lines.
// Yeah, haven't really seen a need to add a console window, though I might
// at some point. --arcum42
namespace Console
{
static const char* tbl_color_codes[] =
static const char *tbl_color_codes[] =
{
"\033[30m" // black
, "\033[31m" // red
@ -69,7 +69,7 @@ __forceinline bool __fastcall Newline()
__forceinline bool __fastcall Write(const char* fmt)
{
if (Config.PsxOut)
puts(fmt);
fputs(fmt, stdout);
if (emuLog != NULL)
fputs(fmt, emuLog);

View File

@ -783,7 +783,7 @@ void SysRunGui()
void *SysMmap(uptr base, u32 size)
{
u8 *Mem;
Mem = mmap((uptr*)base, size, PROT_EXEC | PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, 0, 0);
Mem = (u8*)mmap((uptr*)base, size, PROT_EXEC | PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, 0, 0);
if (Mem == MAP_FAILED) Console::Notice("Mmap Failed!");
return Mem;

View File

@ -180,7 +180,8 @@ std::list<uint> ringposStack;
// debug variable used to check for bad code bits where copies are started
// but never closed, or closed without having been started. (GSRingBufCopy calls
// should always be followed by a call to GSRINGBUF_DONECOPY)
static int copyLock = 0;
// And it's not even used in the debug code.
//static int copyLock = 0;
#endif
typedef void (*GIFRegHandler)(const u32* data);

View File

@ -782,7 +782,9 @@ void injectIRX(const char *filename)
// It might even be a good idea to just go ahead and move them into Win32/Linux
// specific files since they're all #ifdef'd that way anyways.
#ifdef _WIN32
static LARGE_INTEGER lfreq;
#endif
void InitCPUTicks()
{

View File

@ -324,18 +324,22 @@ void _applypatch(int place, IniPatch *p) {
}
}
break;
case CPU_IOP: {
switch (p->type) {
case BYTE_T:
psxMemWrite8(p->addr, (u8)p->data);
break;
case SHORT_T:
psxMemWrite16(p->addr, (u16)p->data);
break;
case WORD_T:
psxMemWrite32(p->addr, (u32)p->data);
break;
}
case CPU_IOP: {
switch (p->type) {
case BYTE_T:
psxMemWrite8(p->addr, (u8)p->data);
break;
case SHORT_T:
psxMemWrite16(p->addr, (u16)p->data);
break;
case WORD_T:
psxMemWrite32(p->addr, (u32)p->data);
break;
default:
break;
}
default:
break;
}
}
}

View File

@ -42,7 +42,7 @@ using namespace R5900; // for R5900 disasm tools
s32 EEsCycle; // used to sync the IOP to the EE
u32 EEoCycle;
static int inter;
//static int inter;
PCSX2_ALIGNED16(cpuRegisters cpuRegs);
PCSX2_ALIGNED16(fpuRegisters fpuRegs);

View File

@ -59,8 +59,8 @@ void statsClose() {
}
void statsVSync() {
static u64 accum = 0, accumvu1 = 0;
static u32 frame = 0;
//static u64 accum = 0, accumvu1 = 0;
//static u32 frame = 0;
stats.eeCycles+= cpuRegs.cycle - stats.eeSCycle;
stats.eeSCycle = cpuRegs.cycle;

View File

@ -177,7 +177,7 @@ void recPLZCW()
GPR_DEL_CONST(_Rd_);
}
static u32 PCSX2_ALIGNED16(s_CmpMasks[]) = { 0x0000ffff, 0x0000ffff, 0x0000ffff, 0x0000ffff };
//static u32 PCSX2_ALIGNED16(s_CmpMasks[]) = { 0x0000ffff, 0x0000ffff, 0x0000ffff, 0x0000ffff };
void recPMFHL()
{

View File

@ -327,7 +327,6 @@ void recUpdateFlags(VURegs * VU, int reg, int info)
//------------------------------------------------------------------
static PCSX2_ALIGNED16(u32 VU_addsuband[2][4]);
static PCSX2_ALIGNED16(u32 VU_addsub_reg[2][4]);
static u32 ecx_temp_loc;
void VU_ADD_SUB(u32 regd, u32 regt, int is_sub, int info)
{

View File

@ -234,6 +234,7 @@ static void iDumpBlock( int startpc, u8 * ptr )
fclose( f );
}
#ifdef PCSX2_VM_COISSUE
static u8 _eeLoadWritesRs(u32 tempcode)
{
switch(tempcode>>26) {
@ -294,6 +295,7 @@ static u8 _eeIsLoadStoreCoX(u32 tempcode)
}
return 0;
}
#endif
void _eeFlushAllUnused()
{
@ -627,6 +629,7 @@ static void recShutdown( void )
x86Shutdown();
}
// Ignored by Linux
#pragma warning(disable:4731) // frame pointer register 'ebp' modified by inline assembly code
void recStep( void ) {

View File

@ -1274,7 +1274,7 @@ void recSLT_const()
}
static u32 s_sltconst = 0x80000000;
static u32 s_sltconst64[2] = {0, 0x80000000};
//static u32 s_sltconst64[2] = {0, 0x80000000};
u32 s_sltone = 1;
void recSLTs_consts(int info, int sign)