diff options
| author | Yong He <yonghe@outlook.com> | 2017-11-04 16:09:48 -0400 |
|---|---|---|
| committer | Yong He <yonghe@outlook.com> | 2017-11-04 16:09:48 -0400 |
| commit | 288841f66c808af70ad7687f9704c87075129b18 (patch) | |
| tree | b6e2e4f5a28be28b28a346f3803121c34bb28f87 /source/slang/vm.cpp | |
| parent | 664e0da8dff1d04860cc46ce8139cbd47e15c552 (diff) | |
fixed all warnings
Diffstat (limited to 'source/slang/vm.cpp')
| -rw-r--r-- | source/slang/vm.cpp | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/source/slang/vm.cpp b/source/slang/vm.cpp index 4b912fb7c..02f8e82fd 100644 --- a/source/slang/vm.cpp +++ b/source/slang/vm.cpp @@ -528,7 +528,7 @@ void computeTypeSizeAlign( } VMType getType( - VM* vm, + VM* /*vm*/, VMTypeImpl* typeImpl) { // TODO: need to look up an existing type that matches... @@ -604,7 +604,7 @@ VMType loadVMType( } } -void* allocateImpl(VM* vm, UInt size, UInt align) +void* allocateImpl(VM* /*vm*/, UInt size, UInt /*align*/) { void* ptr = malloc(size); memset(ptr, 0, size); @@ -666,7 +666,7 @@ void* loadVMSymbol( VMModule* loadVMModuleInstance( VM* vm, void const* bytecode, - size_t bytecodeSize) + size_t /*bytecodeSize*/) { BCHeader* bcHeader = (BCHeader*) bytecode; @@ -739,7 +739,7 @@ void* findGlobalSymbolPtr( } VMThread* createThread( - VM* vm) + VM* /*vm*/) { VMThread* thread = new VMThread(); thread->frame = nullptr; @@ -863,7 +863,7 @@ void resumeThread( case kIROp_BufferStore: { VMType resultType = decodeType(frame, &ip); - UInt argCount = decodeUInt(&ip); + /*UInt argCount = */decodeUInt(&ip); char* bufferData = decodeOperand<char*>(frame, &ip); uint32_t index = decodeOperand<uint32_t>(frame, &ip); @@ -944,10 +944,9 @@ void resumeThread( case kIROp_ReturnVal: { VMType instType = decodeType(frame, &ip); - UInt argCount = decodeUInt(&ip); + /*UInt argCount =*/ decodeUInt(&ip); void* argPtr = decodeOperandPtr<void>(frame, &ip); - VMFrame* oldFrame = frame; VMFrame* newFrame = frame->parent; vmThread->frame = newFrame; @@ -980,7 +979,7 @@ void resumeThread( Int destinationBlock = decodeSInt(&ip); for( UInt aa = 2; aa < argCount; ++aa ) { - void* argPtr = decodeOperandPtr<void>(frame, &ip); + decodeOperandPtr<void>(frame, &ip); } // TODO: we need to deal with the case of @@ -1006,7 +1005,7 @@ void resumeThread( Int falseBlockID = decodeSInt(&ip); for( UInt aa = 4; aa < argCount; ++aa ) { - void* argPtr = decodeOperandPtr<void>(frame, &ip); + decodeOperandPtr<void>(frame, &ip); } Int destinationBlock = *condition ? trueBlockID : falseBlockID; @@ -1025,7 +1024,7 @@ void resumeThread( // knowing too much about an instruction... VMType resultType = decodeType(frame, &ip); - UInt argCount = decodeUInt(&ip); + /*UInt argCount = */decodeUInt(&ip); void* argPtrs[16] = { 0 }; auto leftOpnd = decodeOperandPtrAndType(frame, &ip); auto type = leftOpnd.type; @@ -1050,7 +1049,7 @@ void resumeThread( case kIROp_Mul: { VMType type = decodeType(frame, &ip); - UInt argCount = decodeUInt(&ip); + /*UInt argCount = */decodeUInt(&ip); void* leftPtr = decodeOperandPtr<void>(frame, &ip); void* rightPtr = decodeOperandPtr<void>(frame, &ip); @@ -1072,7 +1071,7 @@ void resumeThread( case kIROp_Sub: { VMType type = decodeType(frame, &ip); - UInt argCount = decodeUInt(&ip); + /*UInt argCount = */decodeUInt(&ip); void* leftPtr = decodeOperandPtr<void>(frame, &ip); void* rightPtr = decodeOperandPtr<void>(frame, &ip); |
