Skip to content

Commit

Permalink
* Quiet some warnings on OS X
Browse files Browse the repository at this point in the history
  • Loading branch information
timangus committed Nov 13, 2005
1 parent 668fdc1 commit e8a953f
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 67 deletions.
2 changes: 0 additions & 2 deletions code/qcommon/unzip.c
Original file line number Diff line number Diff line change
Expand Up @@ -2925,8 +2925,6 @@ int inflate_flush(inflate_blocks_statef *s, z_streamp z, int r)
* For conditions of distribution and use, see copyright notice in zlib.h
*/

static const char inflate_copyright[] =
" inflate 1.1.3 Copyright 1995-1998 Mark Adler ";
/*
If you use the zlib library in a product, an acknowledgment is welcome
in the documentation of your product. If for some reason you cannot
Expand Down
65 changes: 0 additions & 65 deletions code/qcommon/vm_ppc_new.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA

#include "vm_local.h"

#pragma opt_pointer_analysis off

#define DEBUG_VM 0

#if DEBUG_VM
Expand Down Expand Up @@ -523,37 +521,6 @@ static vm_t *tvm;
static int instruction;
static byte *jused;

static void ltop() {
// if (rtopped == qfalse) {
// InstImm( PPC_LWZ, R_TOP, R_OPSTACK, 0 ); // get value from opstack
// }
}

static void ltopandsecond() {
#if 0
if (pass>=0 && buf[compiledOfs-1] == (PPC_STWU | R_TOP<<21 | R_OPSTACK<<16 | 4 ) && jused[instruction]==0 ) {
compiledOfs--;
if (!pass) {
tvm->instructionPointers[instruction] = compiledOfs * 4;
}
InstImm( PPC_LWZ, R_SECOND, R_OPSTACK, 0 ); // get value from opstack
InstImm( PPC_ADDI, R_OPSTACK, R_OPSTACK, -4 );
} else if (pass>=0 && buf[compiledOfs-1] == (PPC_STW | R_TOP<<21 | R_OPSTACK<<16 | 0 ) && jused[instruction]==0 ) {
compiledOfs--;
if (!pass) {
tvm->instructionPointers[instruction] = compiledOfs * 4;
}
InstImm( PPC_LWZ, R_SECOND, R_OPSTACK, -4 ); // get value from opstack
InstImm( PPC_ADDI, R_OPSTACK, R_OPSTACK, -8 );
} else {
ltop(); // get value from opstack
InstImm( PPC_LWZ, R_SECOND, R_OPSTACK, -4 ); // get value from opstack
InstImm( PPC_ADDI, R_OPSTACK, R_OPSTACK, -8 );
}
rtopped = qfalse;
#endif
}

static void spillOpStack(int depth)
{
// Store out each register on the operand stack to it's correct location.
Expand Down Expand Up @@ -593,38 +560,6 @@ static void loadOpStack(int depth)
}
}

static void makeInteger(int depth)
{
// This should really never be necessary...
assert(opStackRegType[depth] == 1);
//assert(opStackRegType[depth] == 2);
if(opStackRegType[depth] == 2)
{
unsigned instruction;
assert(opStackLoadInstructionAddr[depth]);

printf("patching float load at %p to int load\n",opStackLoadInstructionAddr[depth]);
// Repatch load instruction to use LFS instead of LWZ
instruction = *opStackLoadInstructionAddr[depth];
instruction &= ~PPC_LFSX;
instruction |= PPC_LWZX;
*opStackLoadInstructionAddr[depth] = instruction;
opStackLoadInstructionAddr[depth] = 0;
opStackRegType[depth] = 1;
#if 0
InstImm( "stfs", PPC_STFS, opStackFloatRegisters[depth], R_OPSTACK, depth*4+4);
// For XXX make sure we force enough NOPs to get the load into
// another dispatch group to avoid pipeline flush.
Inst( "ori", PPC_ORI, 0, 0, 0 );
Inst( "ori", PPC_ORI, 0, 0, 0 );
Inst( "ori", PPC_ORI, 0, 0, 0 );
Inst( "ori", PPC_ORI, 0, 0, 0 );
InstImm( "lwz", PPC_LWZ, opStackIntRegisters[depth], R_OPSTACK, depth*4+4);
opStackRegType[depth] = 1;
#endif
}
}

static void makeFloat(int depth)
{
//assert(opStackRegType[depth] == 1);
Expand Down

0 comments on commit e8a953f

Please sign in to comment.