[llvm] r196947 - Fix gcc warnings.

Matt Arsenault Matthew.Arsenault at amd.com
Tue Dec 10 10:55:37 PST 2013


Author: arsenm
Date: Tue Dec 10 12:55:37 2013
New Revision: 196947

URL: http://llvm.org/viewvc/llvm-project?rev=196947&view=rev
Log:
Fix gcc warnings.

Unused variable and unused typedef in release build.

Modified:
    llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp
    llvm/trunk/tools/lli/RemoteTargetExternal.cpp

Modified: llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp?rev=196947&r1=196946&r2=196947&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp (original)
+++ llvm/trunk/lib/CodeGen/MachineBlockPlacement.cpp Tue Dec 10 12:55:37 2013
@@ -949,7 +949,9 @@ void MachineBlockPlacement::buildCFGChai
   BlockChain &FunctionChain = *BlockToChain[&F.front()];
   buildChain(&F.front(), FunctionChain, BlockWorkList);
 
+#ifndef NDEBUG
   typedef SmallPtrSet<MachineBasicBlock *, 16> FunctionBlockSetType;
+#endif
   DEBUG({
     // Crash at the end so we get all of the debugging output first.
     bool BadFunc = false;

Modified: llvm/trunk/tools/lli/RemoteTargetExternal.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/lli/RemoteTargetExternal.cpp?rev=196947&r1=196946&r2=196947&view=diff
==============================================================================
--- llvm/trunk/tools/lli/RemoteTargetExternal.cpp (original)
+++ llvm/trunk/tools/lli/RemoteTargetExternal.cpp Tue Dec 10 12:55:37 2013
@@ -80,6 +80,7 @@ void RemoteTargetExternal::SendLoadSecti
                                        uint32_t Size,
                                        bool IsCode) {
   int rc;
+  (void)rc;
   uint32_t MsgType = IsCode ? LLI_LoadCodeSection : LLI_LoadDataSection;
   rc = WriteBytes(&MsgType, 4);
   assert(rc == 4 && "Error writing message type.");
@@ -97,6 +98,7 @@ void RemoteTargetExternal::SendLoadSecti
 
 void RemoteTargetExternal::SendExecute(uint64_t Addr) {
   int rc;
+  (void)rc;
   uint32_t MsgType = (uint32_t)LLI_Execute;
   rc = WriteBytes(&MsgType, 4);
   assert(rc == 4 && "Error writing message type.");
@@ -111,6 +113,7 @@ void RemoteTargetExternal::SendExecute(u
 
 void RemoteTargetExternal::SendTerminate() {
   int rc;
+  (void)rc;
   uint32_t MsgType = (uint32_t)LLI_Terminate;
   rc = WriteBytes(&MsgType, 4);
   assert(rc == 4 && "Error writing message type.");
@@ -121,6 +124,7 @@ void RemoteTargetExternal::SendTerminate
 
 void RemoteTargetExternal::Receive(LLIMessageType ExpectedMsgType) {
   int rc;
+  (void)rc;
   uint32_t MsgType;
   rc = ReadBytes(&MsgType, 4);
   assert(rc == 4 && "Error reading message type.");
@@ -140,6 +144,7 @@ void RemoteTargetExternal::Receive(LLIMe
 
 void RemoteTargetExternal::Receive(LLIMessageType ExpectedMsgType, uint64_t &Data) {
   int rc;
+  (void)rc;
   uint32_t MsgType;
   rc = ReadBytes(&MsgType, 4);
   assert(rc == 4 && "Error reading message type.");





More information about the llvm-commits mailing list