Revision: 13096
Author: [email protected]
Date: Thu Nov 29 07:13:49 2012
Log: Remove unused private member variables found by clang
-Wunused-private-field
Review URL: https://codereview.chromium.org/11414207
Patch from Adam Klein <[email protected]>.
http://code.google.com/p/v8/source/detail?r=13096
Modified:
/branches/bleeding_edge/src/d8.cc
/branches/bleeding_edge/src/deoptimizer.h
/branches/bleeding_edge/src/incremental-marking.cc
/branches/bleeding_edge/src/objects.cc
/branches/bleeding_edge/src/parser.h
/branches/bleeding_edge/src/spaces.h
/branches/bleeding_edge/src/store-buffer.h
/branches/bleeding_edge/test/cctest/test-api.cc
/branches/bleeding_edge/test/cctest/test-heap-profiler.cc
/branches/bleeding_edge/test/cctest/test-lockers.cc
=======================================
--- /branches/bleeding_edge/src/d8.cc Thu Nov 22 00:35:21 2012
+++ /branches/bleeding_edge/src/d8.cc Thu Nov 29 07:13:49 2012
@@ -1511,9 +1511,9 @@
class ShellThread : public i::Thread {
public:
// Takes ownership of the underlying char array of |files|.
- ShellThread(Isolate* isolate, int no, char* files)
+ ShellThread(Isolate* isolate, char* files)
: Thread("d8:ShellThread"),
- isolate_(isolate), no_(no), files_(files) { }
+ isolate_(isolate), files_(files) { }
~ShellThread() {
delete[] files_;
@@ -1522,7 +1522,6 @@
virtual void Run();
private:
Isolate* isolate_;
- int no_;
char* files_;
};
@@ -1829,7 +1828,7 @@
printf("File list '%s' not found\n", options.parallel_files[i]);
Exit(1);
}
- ShellThread* thread = new ShellThread(isolate, threads.length(),
files);
+ ShellThread* thread = new ShellThread(isolate, files);
thread->Start();
threads.Add(thread);
}
=======================================
--- /branches/bleeding_edge/src/deoptimizer.h Wed Nov 7 00:49:17 2012
+++ /branches/bleeding_edge/src/deoptimizer.h Thu Nov 29 07:13:49 2012
@@ -537,9 +537,6 @@
intptr_t context_;
StackFrame::Type type_;
Smi* state_;
-#ifdef DEBUG
- Code::Kind kind_;
-#endif
// Continuation is the PC where the execution continues after
// deoptimizing.
=======================================
--- /branches/bleeding_edge/src/incremental-marking.cc Wed Nov 28 00:43:10
2012
+++ /branches/bleeding_edge/src/incremental-marking.cc Thu Nov 29 07:13:49
2012
@@ -338,10 +338,9 @@
class IncrementalMarkingRootMarkingVisitor : public ObjectVisitor {
public:
- IncrementalMarkingRootMarkingVisitor(Heap* heap,
- IncrementalMarking*
incremental_marking)
- : heap_(heap),
- incremental_marking_(incremental_marking) {
+ explicit IncrementalMarkingRootMarkingVisitor(
+ IncrementalMarking* incremental_marking)
+ : incremental_marking_(incremental_marking) {
}
void VisitPointer(Object** p) {
@@ -368,7 +367,6 @@
}
}
- Heap* heap_;
IncrementalMarking* incremental_marking_;
};
@@ -628,7 +626,7 @@
}
// Mark strong roots grey.
- IncrementalMarkingRootMarkingVisitor visitor(heap_, this);
+ IncrementalMarkingRootMarkingVisitor visitor(this);
heap_->IterateStrongRoots(&visitor, VISIT_ONLY_STRONG);
// Ready to start incremental marking.
=======================================
--- /branches/bleeding_edge/src/objects.cc Wed Nov 28 23:38:00 2012
+++ /branches/bleeding_edge/src/objects.cc Thu Nov 29 07:13:49 2012
@@ -11595,9 +11595,8 @@
public:
explicit SubStringAsciiSymbolKey(Handle<SeqOneByteString> string,
int from,
- int length,
- uint32_t seed)
- : string_(string), from_(from), length_(length), seed_(seed) { }
+ int length)
+ : string_(string), from_(from), length_(length) { }
uint32_t Hash() {
ASSERT(length_ >= 0);
@@ -11654,7 +11653,6 @@
int from_;
int length_;
uint32_t hash_field_;
- uint32_t seed_;
};
@@ -12580,7 +12578,7 @@
int from,
int length,
Object** s) {
- SubStringAsciiSymbolKey key(str, from, length, GetHeap()->HashSeed());
+ SubStringAsciiSymbolKey key(str, from, length);
return LookupKey(&key, s);
}
=======================================
--- /branches/bleeding_edge/src/parser.h Thu Oct 11 04:40:10 2012
+++ /branches/bleeding_edge/src/parser.h Thu Nov 29 07:13:49 2012
@@ -96,7 +96,6 @@
private:
Vector<unsigned> backing_;
- bool owns_data_;
};
=======================================
--- /branches/bleeding_edge/src/spaces.h Wed Nov 28 02:53:39 2012
+++ /branches/bleeding_edge/src/spaces.h Thu Nov 29 07:13:49 2012
@@ -2440,11 +2440,9 @@
FixedSpace(Heap* heap,
intptr_t max_capacity,
AllocationSpace id,
- int object_size_in_bytes,
- const char* name)
+ int object_size_in_bytes)
: PagedSpace(heap, max_capacity, id, NOT_EXECUTABLE),
- object_size_in_bytes_(object_size_in_bytes),
- name_(name) {
+ object_size_in_bytes_(object_size_in_bytes) {
page_extra_ = Page::kNonCodeObjectAreaSize % object_size_in_bytes;
}
@@ -2461,9 +2459,6 @@
private:
// The size of objects in this space.
int object_size_in_bytes_;
-
- // The name of this space.
- const char* name_;
};
@@ -2474,7 +2469,7 @@
public:
// Creates a map space object with a maximum capacity.
MapSpace(Heap* heap, intptr_t max_capacity, AllocationSpace id)
- : FixedSpace(heap, max_capacity, id, Map::kSize, "map"),
+ : FixedSpace(heap, max_capacity, id, Map::kSize),
max_map_space_pages_(kMaxMapPageIndex - 1) {
}
@@ -2515,7 +2510,7 @@
public:
// Creates a property cell space object with a maximum capacity.
CellSpace(Heap* heap, intptr_t max_capacity, AllocationSpace id)
- : FixedSpace(heap, max_capacity, id,
JSGlobalPropertyCell::kSize, "cell")
+ : FixedSpace(heap, max_capacity, id, JSGlobalPropertyCell::kSize)
{}
virtual int RoundSizeDownToObjectAlignment(int size) {
=======================================
--- /branches/bleeding_edge/src/store-buffer.h Fri Oct 12 04:41:14 2012
+++ /branches/bleeding_edge/src/store-buffer.h Thu Nov 29 07:13:49 2012
@@ -210,8 +210,7 @@
explicit StoreBufferRebuildScope(Heap* heap,
StoreBuffer* store_buffer,
StoreBufferCallback callback)
- : heap_(heap),
- store_buffer_(store_buffer),
+ : store_buffer_(store_buffer),
stored_state_(store_buffer->store_buffer_rebuilding_enabled_),
stored_callback_(store_buffer->callback_) {
store_buffer_->store_buffer_rebuilding_enabled_ = true;
@@ -226,7 +225,6 @@
}
private:
- Heap* heap_;
StoreBuffer* store_buffer_;
bool stored_state_;
StoreBufferCallback stored_callback_;
=======================================
--- /branches/bleeding_edge/test/cctest/test-api.cc Tue Nov 27 07:30:12 2012
+++ /branches/bleeding_edge/test/cctest/test-api.cc Thu Nov 29 07:13:49 2012
@@ -17993,7 +17993,6 @@
private:
ThreadInterruptTest* test_;
- struct sigaction sa_;
};
i::Semaphore* sem_;
=======================================
--- /branches/bleeding_edge/test/cctest/test-heap-profiler.cc Wed Oct 17
06:04:49 2012
+++ /branches/bleeding_edge/test/cctest/test-heap-profiler.cc Thu Nov 29
07:13:49 2012
@@ -1015,7 +1015,6 @@
private:
bool disposed_;
- int category_;
int hash_;
const char* group_label_;
const char* label_;
=======================================
--- /branches/bleeding_edge/test/cctest/test-lockers.cc Wed Nov 23 00:36:03
2011
+++ /branches/bleeding_edge/test/cctest/test-lockers.cc Thu Nov 29 07:13:49
2012
@@ -59,9 +59,9 @@
class KangarooThread : public v8::internal::Thread {
public:
KangarooThread(v8::Isolate* isolate,
- v8::Handle<v8::Context> context, int value)
+ v8::Handle<v8::Context> context)
: Thread("KangarooThread"),
- isolate_(isolate), context_(context), value_(value) {
+ isolate_(isolate), context_(context) {
}
void Run() {
@@ -90,7 +90,6 @@
private:
v8::Isolate* isolate_;
Persistent<v8::Context> context_;
- int value_;
};
// Migrates an isolate from one thread to another
@@ -106,7 +105,7 @@
CHECK_EQ(isolate, v8::internal::Isolate::Current());
CompileRun("function getValue() { return 30; }");
}
- KangarooThread thread1(isolate, context, 1);
+ KangarooThread thread1(isolate, context);
thread1.Start();
thread1.Join();
}
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev